From 48a80c7ac3c2ffa6605909c480b060a13c6f4586 Mon Sep 17 00:00:00 2001 From: jef Date: Tue, 24 Nov 2009 20:18:28 +0000 Subject: [PATCH] allow lupdate options like -no-obsolete on update_ts_files.sh git-svn-id: http://svn.osgeo.org/qgis/trunk@12244 c8812cc2-4d05-0410-92ff-de0c093fc19c --- scripts/update_ts_files.sh | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/scripts/update_ts_files.sh b/scripts/update_ts_files.sh index a59a4c51d98..6323aba0378 100755 --- a/scripts/update_ts_files.sh +++ b/scripts/update_ts_files.sh @@ -16,8 +16,13 @@ PATH=$QTDIR/bin:$PATH echo Creating qt_ts.tar tar --remove-files -cvf i18n/qt_ts.tar i18n/qt_*.ts exclude= +opts= for i in "$@"; do - exclude="$exclude --exclude i18n/qgis_$i.ts" + if [ -f "i18n/qgis_$i.ts" ]; then + exclude="$exclude --exclude i18n/qgis_$i.ts" + else + opts=" $i" + fi done if [ -n "$exclude" ]; then tar --remove-files -cvf i18n/qgis_ts.tar i18n/qgis_*.ts$exclude @@ -38,7 +43,7 @@ done echo Creating qmake project file qmake -project -o qgis_ts.pro -nopwd src python i18n echo Updating translation files -lupdate -verbose qgis_ts.pro +lupdate$opts -verbose qgis_ts.pro echo Removing temporary python translation files perl -i.bak -ne 'print unless /^\s+