diff options
author | David P <megver83@parabola.nu> | 2017-07-29 21:59:30 -0400 |
---|---|---|
committer | David P <megver83@parabola.nu> | 2017-07-29 21:59:30 -0400 |
commit | 5e9742f03e4199c006b0f9d0d8069a2fb41d9258 (patch) | |
tree | c5e7c30625b30b50a2a2385ef934c1d7e57eb2fa /po/HACKING | |
parent | 63f4ac3c0a6ea7e060720b63964cf158157fc785 (diff) | |
parent | 0b8606e0cd0e1aedfe222d4d6603c4986aacb7b5 (diff) |
Diffstat (limited to 'po/HACKING')
-rw-r--r-- | po/HACKING | 19 |
1 files changed, 13 insertions, 6 deletions
@@ -2,19 +2,24 @@ Translations for programs are provided in files with the `.po` suffix. These are created by copying PO-template (`.pot`) files, and filling in the missing "msgstr" values. -To add a translation, you'll first (1) need to create the `.pot` -files, and then (2) copy them and (3) fill them in. +To add a translation, you'll first (1) need to create the `.pot` files +if you don't already have them, and then (2) copy them and (3) fill +them in. # 1. Create `.pot` files + If you are working from a release source tarball, you can skip this + step (the `.pot` files are included in the tarball); if you are + working from git, read on. + libretools' .pot files are not tracked in git; they are created by - running `make` (you'll need a checkout of both devtools-par and - libretools to run `make` if building from git): + running `make`. You'll need a checkout of both "devtools-par" and + "libretools" to run `make` if building from git. $ git clone https://git.parabola.nu/packages/devtools-par.git/ $ git clone https://git.parabola.nu/packages/libretools.git/ $ cd libretools - $ make + $ make po/files.generate ... $ cd po/ $ ls @@ -29,10 +34,12 @@ files, and then (2) copy them and (3) fill them in. Create a folder under `po/` with the two-letter language code[^1] you want to add. Then, copy the `.pot` files to that folder, - changing the file extension to `.po`; for example: + changing the file extension to `.po`. Finally, link the `subdir.mk` + file to be the Makefile for that directory. For example: $ mkdir es $ for file in *.pot; do cp $file es/${file%t}; done + $ ln -s ../subdir.mk es/Makefile [^1]: See the langauge code table here: <http://www.lingoes.net/en/translator/langcode.htm> |