Extension Localisation Wiki using Translate/Exporting Translations
From MediaWiki.org
There are two methods of exporting translations using the Translate extension.
[edit] Maintenance Script
The main method of exporting translations is to use a maintenance script, this is faster and can be scripted if desired.
Navigate to the Translate extension directory, for example:
cd /var/www/w/extensions/Translate/
Then run the export.php script in the scripts/ directory using the parameters:
- --lang=
- *
- --group=
- Internal name of group to export. (As specified using the setId method in LocalSettings.php.)
- --target=
- Output directory, e.g. ..
An example could be:
php scripts/export.php --lang=* --group=ExtensionRenameUser --target=/home/administrator/messages/
The messages file will be exported in to the directory you specified and can be retrieved over SFTP, or utilised in any other fashion from the command line.
[edit] Special:Translate
| This method is known to be inefficient and can produce broken output. It should not be used. |
Translation files can be exported on a per extension basis from the Special:Translate page.
You should press the edit button beside the extension you wish to export messages for, and then select "Export translations to file from" from the "I want to" box. When you press "Fetch" the PHP file will load, you can then save this and upload it to your version control repository.
Repeat this process for all extensions you wish to export.