aboutsummaryrefslogtreecommitdiff
path: root/includes/php-gettext/examples/update
diff options
context:
space:
mode:
authormensonge <mensonge@b3834d28-1941-0410-a4f8-b48e95affb8f>2007-12-12 16:29:16 +0000
committermensonge <mensonge@b3834d28-1941-0410-a4f8-b48e95affb8f>2007-12-12 16:29:16 +0000
commitd582054c77b22daeb08d2bff17794b9a69a20dd4 (patch)
treed6e7cef8639da6f573cd0b21a5316abf5af24fac /includes/php-gettext/examples/update
downloadsemanticscuttle-d582054c77b22daeb08d2bff17794b9a69a20dd4.tar.gz
semanticscuttle-d582054c77b22daeb08d2bff17794b9a69a20dd4.tar.bz2
import of scuttle 0.7.2
git-svn-id: https://semanticscuttle.svn.sourceforge.net/svnroot/semanticscuttle/trunk@1 b3834d28-1941-0410-a4f8-b48e95affb8f
Diffstat (limited to 'includes/php-gettext/examples/update')
-rw-r--r--includes/php-gettext/examples/update14
1 files changed, 14 insertions, 0 deletions
diff --git a/includes/php-gettext/examples/update b/includes/php-gettext/examples/update
new file mode 100644
index 0000000..c8d8b61
--- /dev/null
+++ b/includes/php-gettext/examples/update
@@ -0,0 +1,14 @@
+#!/bin/sh
+TEMPLATE=pigs.pot
+xgettext -kT_ngettext:1,2 -kT_ -L PHP -o $TEMPLATE pigs.php
+if [ x$1 == 'x-p' ]; then
+ msgfmt --statistics $TEMPLATE
+else
+ if [ -f $1.po ]; then
+ msgmerge -o .tmp$1.po $1.po $TEMPLATE
+ mv .tmp$1.po $1.po
+ msgfmt --statistics $1.po
+ else
+ echo "Usage: $0 [-p|<basename>]"
+ fi
+fi