[GRASS-SVN] r59157 - grass/trunk/locale

svn_grass at osgeo.org svn_grass at osgeo.org
Sat Mar 1 09:56:30 PST 2014


Author: marisn
Date: 2014-03-01 09:56:30 -0800 (Sat, 01 Mar 2014)
New Revision: 59157

Modified:
   grass/trunk/locale/Makefile
Log:
Extract messages with multiple plural forms to POT files

Modified: grass/trunk/locale/Makefile
===================================================================
--- grass/trunk/locale/Makefile	2014-03-01 17:55:31 UTC (rev 59156)
+++ grass/trunk/locale/Makefile	2014-03-01 17:56:30 UTC (rev 59157)
@@ -31,9 +31,9 @@
 WXPYDOMAIN = grasswxpy
 DOMAINS = $(LIBDOMAIN) $(MODDOMAIN) $(WXPYDOMAIN)
 
-LIB_POTFILES = find ../lib \( -name "*.c" -o -name "*.py" \) | xargs grep -l "_(\""
-MOD_POTFILES = find ../ -name '*.c' | grep -v '../lib' | xargs grep -l "_(\""
-WXPY_POTFILES = find ../gui/wxpython -name '*.py' | xargs grep -l "_(\""
+LIB_POTFILES = find ../lib \( -name "*.c" -o -name "*.py" \) | xargs grep -l "_(\"\|_n(\""
+MOD_POTFILES = find ../ -name '*.c' | grep -v '../lib' | xargs grep -l "_(\"\|_n(\""
+WXPY_POTFILES = find ../gui/wxpython -name '*.py' | xargs grep -l "_(\"\|_n(\""
 
 define po_stats
 GISBASE="$(RUN_GISBASE)" $(PYTHON) ./grass_po_stats.py
@@ -47,11 +47,11 @@
 		exit 1 ; \
 	fi
 	@echo "Generating $(LIBDOMAIN)..."
-	xgettext -k_ -cGTC -o ./templates/$(LIBDOMAIN).pot `$(LIB_POTFILES)`
+	xgettext --keyword=_ --keyword=_n:1,2 -cGTC -o ./templates/$(LIBDOMAIN).pot `$(LIB_POTFILES)`
 	@echo "Generating $(MODDOMAIN)..."
-	xgettext -k_ -cGTC -o ./templates/$(MODDOMAIN).pot `$(MOD_POTFILES)`
+	xgettext --keyword=_ --keyword=_n:1,2 -cGTC -o ./templates/$(MODDOMAIN).pot `$(MOD_POTFILES)`
 	@echo "Generating $(WXPYDOMAIN)..."
-	xgettext -k_ -cGTC -o ./templates/$(WXPYDOMAIN).pot `$(WXPY_POTFILES)` 
+	xgettext --keyword=_ --keyword=_n:1,2 -cGTC -o ./templates/$(WXPYDOMAIN).pot `$(WXPY_POTFILES)` 
 
 #merge already existing translations with new messages in POT template file and create new po files:
 update-po:



More information about the grass-commit mailing list