From baa727de93db009f90d70a80a9861758a24eae77 Mon Sep 17 00:00:00 2001 From: Jo-Philipp Wich Date: Tue, 5 Nov 2019 10:27:59 +0100 Subject: docs: rename documentation folder to docs Signed-off-by: Jo-Philipp Wich --- docs/i18n.md | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100644 docs/i18n.md (limited to 'docs/i18n.md') diff --git a/docs/i18n.md b/docs/i18n.md new file mode 100644 index 000000000..226a406c2 --- /dev/null +++ b/docs/i18n.md @@ -0,0 +1,19 @@ +# General +Translations are saved in the folder po/ for each module and application. You find the reference in po/templates/.pot. The actual translation files can be found at po/[lang]/[package].po . + +In order to use the commands below you need to have the _gettext'' utilities (''msgcat'', ''msgfmt'', ''msgmerge_) installed on your system. + +# Rebuild po files +If you want to rebuild the translations after you made changes to a package this is an easy way: + + ./build/i18n-scan.pl applications/[application] > applications/[application]/po/templates/[application_basename].pot + ./build/i18n-update.pl applications/[application]/po + + Example: + ./build/i18n-scan.pl applications/luci-app-firewall > applications/luci-app-firewall/po/templates/firewall.pot + ./build/i18n-update.pl applications/luci-app-firewall/po + (note that the directory argument can be omitted for i18n-update.pl to update all apps) + +*Note:* Some packages share translation files, in this case you need to scan through all their folders. The first command from above should then be: + + ./build/i18n-scan.pl applications/[package-1] applications/[package-2] applications/[package-n] > [location of shared template]/[application].pot -- cgit v1.2.3