Comment 1 for bug 867977

Revision history for this message
Данило Шеган (danilo) wrote :

A related bug is bug 651844, where we'd make all the bzr branches available through git. I know there was desire to make this work, but it's a non-trivial thing to do.

As far as translations goes, while Launchpad can not commit translations to your external repository directly, it was always my impression that maintainers would not be very eager to let other tools have an option of directly committing to a repository. I was hoping transifex would have turned into a project providing a server side, usually hosted by the project maintainers and defining policy, and a protocol for submitting translations. In such a case, Launchpad would have implemented this protocol and could talk to any of the servers. Maintainers would be able to define strict policy on the server side knowing that it's them who are controlling what can be modified in their repositories, and not giving full access to external sources. Alas, this was not to be :)

Anyway, for the time being, I'd propose using Launchpad in the following way to make things as automated as possible for you:
 1. Get your git branch imported into LP
 2. Set up translation imports from that branch in LP
 3. Set up translation exports to a separate branch in LP, perhaps even entirely empty otherwise (translation exports are done once a day if there are any changes)
 4. Run cronscripts on your side that do something as simple as "bzr branch lp:~your/export/branch bzr-branch && cp bzr-branch/po/*.po your-git-trunk/po && cd your-git-trunk && git commit -m 'Merge translations from LP.'".

This would basically implement a policy on your side (i.e. "copy only po/*.po files"), thus restricting the damage Launchpad could do. Even though Launchpad is generally very smart about merging translations between several sources, you could also do more magic with msgmerge instead of just copying files, but that's also part of the policy that would be specific to your project.

Of course, you'd usually want to run this on an always-on machine and unattended, so it might be nice if there was service providing it. But, I believe this will allows you an easy way to automate stuff with Launchpad already.