summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPierre GRANDIN <grandinp@altern.org>2015-12-24 10:51:24 -0800
committerPierre GRANDIN <grandinp@altern.org>2015-12-24 10:51:24 -0800
commita683fe8df645973b3e8956e8d937f8b2f096ca42 (patch)
tree61ef1828d245a8cfa1bc7db30f68ceed13349b18
parent910720ff935a17ea52c189d34906288feef00d89 (diff)
downloadnavit-R6438.tar.gz
Fix:i18n:Fixed the translation import scriptR6438
-rw-r--r--ci/import_translations.sh12
1 files changed, 4 insertions, 8 deletions
diff --git a/ci/import_translations.sh b/ci/import_translations.sh
index 38bb244c6..33d94e9c4 100644
--- a/ci/import_translations.sh
+++ b/ci/import_translations.sh
@@ -6,6 +6,7 @@ for i in po/import_queue/*.po; do
b=`basename $i`;
po=${b#*-};
code=${po%.*}
+ git checkout -b i18n/$code
lname=`head -n1 ${i} | sed 's/# \(.*\) translation.\{0,1\} for navit/\1/'`
if [[ $lname == "" ]]; then
echo "Cannot find the language name in the header of $i"
@@ -37,12 +38,7 @@ for i in po/import_queue/*.po; do
mv po/${po}.header po/${po}.in
sed '1,/msgid ""/ d' ${i} >> po/${po}.in
- git rm -f $i
-
- # Archive the po
- [ -d $CIRCLE_ARTIFACTS/po ] || mkdir $CIRCLE_ARTIFACTS/po
- cp po/${po}.in $CIRCLE_ARTIFACTS/po/
- # Yay, we should have a clean .po file now!
- git --no-pager diff po/${po}.in
+ git add po/${po}.in && rm $i
+ git commit -m "Updated ${lname} translation from launchpad" po/${po}.in
+ git push --set-upstream origin i18n/${code}
done
-