Hi

Dne Fri, 9 Jan 2015 12:26:27 +0000
Emese Kovacs <[email protected]> napsal(a):

> I am trying to setup a translation process involving weblate. We are using
> gettext po files as format and git as version control system with git flow
> branching, the project we are working on is a website.
> 
> My idea right now is:
> 
> 1. Developer writes code, source code is in git. Strings are marked up for
> translation in source.
> 2. Developer pushes code to remote, merges feature branch to develop.
> 3. Merge to develop triggers update on weblate via notifications hook
> 4. Weblate pulls changes, rebuilds pot files based on updated source, uses
> msgmerge to update po files, loads updated po files into weblate (this is
> the main bit I still have to figure out)

Weblate does not update translation templates at all, see
https://docs.weblate.org/en/latest/faq.html#does-weblate-update-translation-files-besides-translations

> 5. Translators translate
> 6. Translations get committed and pushed back to develop
> 7. Develop gets automatically deployed to our testing environment where
> translators can check translations in context and test translated site
> 
> My questions are:
> * what exactly does weblate do on update? Does it only pull from git, or
> does it also reload po files (if there are changes, like new strings).

It checks for changes in translation files (eg. po) and reloads them if
needed.

> * is it possible to specify a script to run post-update on weblate's end? I
> am trying to figure out what the best way is to handle pot generation and
> po file update (msgmerge). Following weblate's philosophy, should it be
> done on the developer's end, or should it be done on weblate's end? The
> goal is to automate the process as much as possible, to provide new strings
> to translators as fast as possible.

It's best to do on the developer end as this way you can do it only
when it is needed. There is no cheap way to figure out if translations
have changed. Also this usually involves quite a lot of project
specific logic...

> * I have seen you can configure weblate to push on commit, but can weblate
> be setup to commit automatically (for example when the translator lock
> times out)? Or do I have to have cron job running to pull, merge, commit,
> push from time to time (possibly using manage.py trans commands like
> commit_pending).

Yes, it commits automatically, see documentation for more details when
commits happen:

https://docs.weblate.org/en/latest/admin/continuous.html#lazy-commits

-- 
        Michal Čihař | http://cihar.com | http://blog.cihar.com

Attachment: pgpISw082VmpF.pgp
Description: OpenPGP digital signature

_______________________________________________
Weblate mailing list
[email protected]
https://lists.cihar.com/cgi-bin/mailman/listinfo/weblate

Reply via email to