[TYPO3-v4] Git submodules or not?

Ernesto Baschny [cron IT] ernst at cron-it.de
Mon Aug 22 10:43:48 CEST 2011


Jigal van Hemert schrieb am 22.08.2011 10:28:
> Hi,
> 
> On 22-8-2011 9:45, Ernesto Baschny [cron IT] wrote:
>>   + makes the life for developers a bit easier since the just work with
>>     one source directory and git takes care to put the things to the
>>     accordant repositories and branches there
> 
> Can you explain this a bit more? What is from a functional point of view
> the advantage (not the technical difference)?
> 
> Let's use DBAL (and Xavier as the DBAL 'team') as an example (it's
> easier to talk about a concrete example, so nothing personal here :-) ).
> 
> With submodules I have to update them frequently and when I want to push
> something for DBAL I have to do this from the DBAL directory.
> With and without submodules git seems to know which files belong with
> which branch (at least it looks that way to me).
> 
> What can Xavier do with submodules that he can't do without submodules?
> Is this advantage so important for him that this out-ways the
> inconvenience for other developers?

The advantage is not for Xavier, but for the rest of the team:

We are all working with Xavier's repository under the hood, and not some
"copy" that was manually merged into our repository. So its just a
matter of changing a pointer if we need a new version. It cannot happen
that we diverge. It cannot happen that someone accidentally commits
something to typo3conf/ext/dbal in the core, because it isn't present
physically in the core.

So a Peter once said: One project, one history.

With "Subtree merges", the DBAL project would have two different
histories, which are not directly linked together: Xavier's DBAL
repository, and then the Core subdirectory which contains different SHA1
commits.

So finding *the commit* which broke the core is a bit more difficult, if
it happens in one of the merged projects.

These advantages makes the submodule way of doing it "cleaner". But I
have my doubts if these advantages are worth all the hassle we are
dealing with on a daily basis. As soon as we branch 4.6 we *will* have
even more submodules (e.g. Linkvalidator).

Cheers,
Ernesto


More information about the TYPO3-project-v4 mailing list