summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTails developers <amnesia@boum.org>2013-06-22 12:23:49 +0000
committerTails developers <amnesia@boum.org>2013-06-23 15:44:09 +0200
commit2411bdecf628a0260436874566c7b892fae7cea8 (patch)
tree39e969afee338ff8d492768f610a4bd84aa7aec2
parentacf51c16f11888c4a8483342cc6d6782138e4d50 (diff)
Error out if there are left out files which should have been listed in POTFILES.in or POTFILES.skip.
-rwxr-xr-xrefresh-translations11
1 files changed, 11 insertions, 0 deletions
diff --git a/refresh-translations b/refresh-translations
index 3de6280..7d078b2 100755
--- a/refresh-translations
+++ b/refresh-translations
@@ -79,6 +79,12 @@ refresh_mo () {
done
}
+no_left_out_files () {
+ (cd po && intltool-update --maintain)
+ [ ! -e po/missing ] || return 1
+ return 0
+}
+
intltool_update () {
cd po
intltool-update -x --pot --gettext-package=tails
@@ -95,9 +101,14 @@ for prog in $PERL_PROGS ; do refresh_pot $prog Perl ; done
for prog in $PYTHON_PROGS ; do refresh_pot $prog Python ; done
for prog in $SHELL_PROGS ; do refresh_pot $prog Shell ; done
+# If left out files are detected, intltool-update --maintain writes
+# them to po/missing.
+no_left_out_files || exit 3
+
concat_pot_files $PERL_PROGS $PYTHON_PROGS $SHELL_PROGS > $POTFILE
refresh_po $POTFILE $LANGUAGES
refresh_mo $LANGUAGES
intltool_update $LANGUAGES
+