Re: git submodules vs translators



Hi all,

Colin Walters <walters verbum org>, Thu, 27 Jun 2013 20:01:33 -0400:

The use of git submodules in GNOME is growing - there's libgd,
egg-list-box, and my own libgsystem, among others.  Broadly speaking, I
think that's a good thing.  They offer a reasonable set of tradeoffs
compared to "copylibs" like the old libegg model.

However, git submodules are easy to screw up unless everyone committing
to the repository is aware of how they work.  This collides badly with
our current translation system where many translators commit directly to
git, resulting in commits like this one:

https://git.gnome.org/browse/gnome-control-center/commit/?id=c87483acb4cce36ffad215396dbaa4cea801c970

That commit reverted two submodules.  The gnome-ostree continuous
integration system made it fairly obvious when I looked at the build
error, but two things should happen:

1) Translators:  Ensure you run "git submodule update --init" after
   every git pull.

Thanks for bringing this up.

We already suggest in one of our GNOME L10n HOWTOs that translators
set up a git alias for git pull --rebase, so we may just need to expand
it to talk about an alias for "git pull --rebase && git submodule
update --init":

https://wiki.gnome.org/TranslationProject/GitHowTo

2) We need some sort of sanity check in a pre-receive hook.  Something  
   like "commits whose subjects match the regexp "Update.*translation"
   are rejected if they modify submodules.

Not all translators seem to use the same commit messages, so instead, we
probably want to check for commits changing *.po files in po*/ dirs or
something like that...

   Or even stronger, one idea is that modules can opt-in to having a
   file "submodule-check" which must change content for commits which
   update submodules.  The downside of that is it would conflict
   on branch merges, but then again, the submodules would anyways.

Any other thoughts?

I agree with Fred that having 
https://bugzilla.gnome.org/show_bug.cgi?id=599066 addressed would
definitely help us, also in terms of making the whole translation process
easier and more straightforward, especially for translators who are less
experienced or technical.

Cheers,
Petr Kovar


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]