Skip to content

Commit

Permalink
Move information about translations to po/README.md
Browse files Browse the repository at this point in the history
  • Loading branch information
zas committed Jan 13, 2014
1 parent 683dc64 commit 9c3f0ae
Show file tree
Hide file tree
Showing 2 changed files with 52 additions and 16 deletions.
17 changes: 1 addition & 16 deletions HACKING.txt
Original file line number Diff line number Diff line change
@@ -1,19 +1,4 @@
Translations
============

Picard translations are handled by Transifex. Please do not manually edit the
PO files, only use the transifex client to update the template
or fetch translations.

https://www.transifex.net/projects/p/musicbrainz/resource/picard/
http://help.transifex.com/features/client/

Updating the translation template after adding/removing some strings:

$ pybabel extract contrib picard -o po/picard.pot
$ tx push -s

Fetching latest translations from Transifex:

$ python setup.py get_po_files

See po/README.md for information about translations.
51 changes: 51 additions & 0 deletions po/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
Translations
============

Picard translations are handled by [Transifex](https://www.transifex.com).

_Please do not manually edit the PO files._

Required tools
--------------

* [Transifex client](http://support.transifex.com/customer/portal/topics/440187-transifex-client/articles)
* [Babel](http://babel.pocoo.org/)


Picard source tree strings
--------------------------

Their translations are handled at https://www.transifex.com/projects/p/musicbrainz/resource/picard/

Picard maintainers can update `picard.pot` using:
```bash
$ python setup.py regen_pot_file
```

Transifex will _automatically_ pick `picard.pot` from [Picard git repository master branch](https://github.com/musicbrainz/picard/tree/master) once per day.


`picard/countries.py` strings
-----------------------------

Their translations are handled at https://www.transifex.com/projects/p/musicbrainz/resource/countries/

`countries.pot` is generated from musicbrainz database, using `po/extract_pot_db` from [musicbrainz-server project](https://bitbucket.org/metabrainz/musicbrainz-server/), outside the Picard project.

Picard maintainers can regenerate `picard/countries.py`, which is using `countries.pot` as base, using the command:
```bash
$ python setup.py update_countries
```
It will retrieve and parse latest `countries.pot` to rebuild `picard/countries.py`.


To fetch latest translations from Transifex
-------------------------------------------

Use the following command:

```bash
$ python setup.py get_po_files
```

It will fetch all po files from Transifex with at least 5% translations done (this is defined by `TXPULL_CMD` in `setup.py`).

0 comments on commit 9c3f0ae

Please sign in to comment.