Administration

Administration of Weblate is done through standard Django admin interface, which is available under /admin/ URL.

Adding new resources

All translation resources need to be available as Git repositories and are organized as project/subproject structure.

Weblate supports wide range of translation formats supported by translate toolkit, for example:

  • GNU Gettext
  • XLIFF
  • Java properties
  • Windows RC files
  • Qt Linguist .ts
  • Symbian localization files
  • CSV
  • INI

Project

To add new resource to translate, you need to create translation project first. The project is sort of shelf, in which real translations are folded. All subprojects in same project share suggestions and dictionary, also the translations are automatically propagated through the all subproject in single project.

Subproject

Subproject is real resource for translating. You enter Git repository location and file mask which files to translate and Weblate automatically fetches the Git and finds all translated files.

Примечание

As setup of translation project includes fetching Git repositories, you might want to preseed these, repos are stored in path defined by GIT_ROOT in settings.py in <project>/<subproject> directories.

Updating repositories

You should set up some way how backend repositories are updated from their source. You can either use hooks (see Interacting with others) or just regularly run ./manage.py updategit --all.

With Gettext po files, you might be often bitten by conflict in PO file headers. To avoid it, you can use shipped merge driver (scripts/git-merge-gettext-po). To use it just put following configuration to your .gitconfig:

[merge "merge-gettext-po"]
  name = merge driver for gettext po files
  driver = /path/to/weblate/scripts/git-merge-gettext-po %O %A %B

And enable it’s use by defining proper attributes in given repository (eg. in .git/info/attribute):

*.po merge=merge-gettext-po

Примечание

This merge driver assumes the changes in POT files always are done in brach we’re trying to merge.

Interacting with others

You can trigger update of underlaying git repository for every subproject by accessing URL /hooks/p/project/subproject/update/. This can be used for example as as Post-Receive URLs on Github.