From cd299d0495fd737159d4d20e4cdd04501e32b738 Mon Sep 17 00:00:00 2001 From: Fabio Erculiani Date: Tue, 3 Apr 2012 16:03:06 +0200 Subject: [PATCH] [po] move transifex scripts to Makefile, add "validate" Makefile target --- misc/po/Makefile | 16 ++++++++++++++-- misc/po/TRANSIFEX_README | 4 ++-- misc/po/transifex_pull.sh | 2 -- misc/po/transifex_push.sh | 2 -- 4 files changed, 16 insertions(+), 8 deletions(-) delete mode 100755 misc/po/transifex_pull.sh delete mode 100755 misc/po/transifex_push.sh diff --git a/misc/po/Makefile b/misc/po/Makefile index 10c5ec831..d94d6225f 100644 --- a/misc/po/Makefile +++ b/misc/po/Makefile @@ -22,8 +22,20 @@ POTFILES.in: $(NLSPACKAGE).pot: $(POTFILES) POTFILES.in intltool-update --gettext-package=$(NLSPACKAGE) --pot -update-po: Makefile $(NLSPACKAGE).pot - ./transifex_pull.sh +transifex-pull: + tx pull -a -f + +transifex-push: + tx push -s + +validate: + catalogs='$(CATALOGS)'; \ + for cat in $$catalogs; do \ + lang=`basename $$cat .po`; \ + msgfmt -c $$lang.po -o /dev/null || exit 1; \ + done + +update-po: Makefile $(NLSPACKAGE).pot transifex-pull refresh-po: Makefile POTFILES.in catalogs='$(CATALOGS)'; \ diff --git a/misc/po/TRANSIFEX_README b/misc/po/TRANSIFEX_README index f159ebe66..9d8869097 100644 --- a/misc/po/TRANSIFEX_README +++ b/misc/po/TRANSIFEX_README @@ -9,10 +9,10 @@ UPLOAD and pushed using: - $ sh transifex_push.sh # requires transifex-client + $ sh transifex-push # requires transifex-client DOWNLOAD ======== .po files are downloaded via: - $ sh transifex_pull.sh # requires transifex-client + $ sh transifex-pull # requires transifex-client diff --git a/misc/po/transifex_pull.sh b/misc/po/transifex_pull.sh deleted file mode 100755 index 8f5bbad13..000000000 --- a/misc/po/transifex_pull.sh +++ /dev/null @@ -1,2 +0,0 @@ -#!/bin/sh -tx pull -a -f diff --git a/misc/po/transifex_push.sh b/misc/po/transifex_push.sh deleted file mode 100755 index 46e1956a8..000000000 --- a/misc/po/transifex_push.sh +++ /dev/null @@ -1,2 +0,0 @@ -#!/bin/sh -tx push -s