I am trying to switch to Composer / Packagist , and for this purpose I am trying to figure out how best to manage my workflow so that I can create pacakges composer with my selection and application map, but damn if I can figure out the way to do it with Git / Github or Hg / BitBucket (or both).
Current structure / workflow
%path%/sites/[framework] - contains up to date framework git repo %path%/sites/[framework]/application - contains app specific code and is a bitbucket repo *%path%/www/[appname]_public - contains public files and is a bitbucket repo ie "public_html" folder
With the proper alias, this works for my current sites (each site is a separate folder in "/ sites"). And since I use two separate repo mechanisms, I can update the framework for this particular site whenever I want it to not damage my application and vice versa.
Since packages are contained as subfolders of the application folder (so I can create and test them), how can I βwrapβ these folders as packages as separate repositories so that I can provide them as standalone composer packages on github or a bitpack? I was a little confused.
%path%/sites/[framework]/application/[module] - contains controllers, models, views, etc... to be wrapped up as a composer "package" and made available on github or bitbucket as its own repo.
Perhaps someone here can give me a hand with logic about this or how to set it up, since I cannot figure out how to do this. Is it possible? Can I / think about a problem?
Maybe my whole way of thinking is wrong. With my existing structure, I tried to complete the task, but Git Submodules or HG nested repositories do not work as I expected.
Is my workflow a serious flaw or do I need more Git knowledge for this? Is there an easier / better way? I will happily rebuild my structure / workflow if I can save Framework / SiteApplicationCode / Packages as separate repositories with some mechanism / logic that I am missing.
Thanks in advance for any help.