Commit fc83826b authored by Richard Mansfield's avatar Richard Mansfield

Only push modified .po files for master

parent 09fee16a
...@@ -123,26 +123,29 @@ for branch in ${branches} ; do ...@@ -123,26 +123,29 @@ for branch in ${branches} ; do
bzr add mahara/mahara.pot bzr add mahara/mahara.pot
bzr commit -m "Update template to ${remotecommit}" bzr commit -m "Update template to ${remotecommit}"
# Update all the .po files from the export repo to avoid unnecessary invalidation if [ $branch = 'master' ] ; then
# of existing translations # Update all the .po files from the export repo to avoid unnecessary invalidation
exportbranch=${branch}-export # of existing translations
if [ ! -d ${BZR}/${exportbranch} ]; then
bzr branch lp:~mahara-lang/mahara-lang/${exportbranch} ${BZR}/${exportbranch} exportbranch=${branch}-export
else if [ ! -d ${BZR}/${exportbranch} ]; then
cd ${BZR}/${exportbranch} bzr branch lp:~mahara-lang/mahara-lang/${exportbranch} ${BZR}/${exportbranch}
bzr pull else
fi cd ${BZR}/${exportbranch}
bzr pull
for po in `ls ${BZR}/${exportbranch}/mahara/*.po`; do fi
pobase=${po##*/}
/usr/bin/perl ${SCRIPTS}/update-po-from-pot.pl $po mahara/mahara.pot mahara/$pobase for po in `ls ${BZR}/${exportbranch}/mahara/*.po`; do
done pobase=${po##*/}
/usr/bin/perl ${SCRIPTS}/update-po-from-pot.pl $po mahara/mahara.pot mahara/$pobase
podiffs=`bzr diff mahara` done
if [ ! -z "$podiffs" ] ; then podiffs=`bzr diff mahara`
bzr add mahara
bzr commit -m "Update translations to ${remotecommit}" if [ ! -z "$podiffs" ] ; then
bzr add mahara
bzr commit -m "Update translations to ${remotecommit}"
fi
fi fi
# Push everything to lp:mahara-lang # Push everything to lp:mahara-lang
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment