Re: Projects within projects
- From
Avery Pennarun <apenwarr@gmail.com>
- Date
- Oct 29, 2009, 18:56 UTC
- Message-ID
- <32541b130910291156w693a188dv6dfd0d39a506d145@mail.gmail.com>
- In-Reply-To
- <ab1d51700910291140ncd80027j4ee9a30637d7bc40@mail.gmail.com>
On Thu, Oct 29, 2009 at 2:40 PM, Nick Colgan <nick.colgan@gmail.com> wrote:
Show 14 quoted lines
> These are the current options I have in mind: > > 1. Create a separate repository for each sub-project and manage each > separately in redmine (separate bug tracker, wiki, etc.) > > 2. Create a single repository with a subdirectory for each sub-project. > > 3. Use git submodules or subversion externals to combine options 1 and 2 > by creating a separate repo for each sub-project, then creating a master > repo with subdirectory for each sub-project that imports from their > respective repositories. > > What's the best way to handle this situation? Are git submodules and/or > svn externals sufficiently capable of dealing with this?
Every way has tradeoffs. I'd suggest first thinking about whether these supposedly independent projects are *really* going to be independent or not. If they're unlikely to ever be reused - or they won't be for a long time - #2 is by far the easiest choice.
If you choose #2 and then choose to split the repo later, you can use git-subtree (http://github.com/apenwarr/git-subtree) to split it easily, so there's little sacrifice in using #2 at first and changing your mind later.
If you choose #3, that's exactly that git-submodule and svn:externals are for, and it seems to work okay for a lot of people. It's more work though, since you have to be careful to isolate commits between one project and another, etc. Personally I prefer to use git-subtree for this too, but it's a matter of preference.
Have fun,
Avery