devtools: Use pybabel in virtualenv or on path depending on which is present.
* devtools/update_translations.sh (PYBABEL): New variable, points to whichever pybabel we should use.
This commit is contained in:
parent
1c6c97c5aa
commit
c01572e97f
@ -19,6 +19,12 @@
|
|||||||
# exit if anything fails
|
# exit if anything fails
|
||||||
set -e
|
set -e
|
||||||
|
|
||||||
|
if [ -f "./bin/pybabel" ]; then
|
||||||
|
PYBABEL="./bin/pybabel";
|
||||||
|
else
|
||||||
|
PYBABEL=pybabel;
|
||||||
|
fi
|
||||||
|
|
||||||
echo "==> checking out master"
|
echo "==> checking out master"
|
||||||
git checkout master
|
git checkout master
|
||||||
|
|
||||||
@ -29,7 +35,7 @@ echo "==> pulling present translations"
|
|||||||
rsync --exclude-from="devtools/pootle-exclude.txt" -vaz chapters.gnu.org::pootle/mediagoblin/ mediagoblin/i18n/
|
rsync --exclude-from="devtools/pootle-exclude.txt" -vaz chapters.gnu.org::pootle/mediagoblin/ mediagoblin/i18n/
|
||||||
|
|
||||||
echo "==> Extracting translations"
|
echo "==> Extracting translations"
|
||||||
./bin/pybabel extract -F babel.ini -o mediagoblin/i18n/templates/mediagoblin.pot .
|
$PYBABEL extract -F babel.ini -o mediagoblin/i18n/templates/mediagoblin.pot .
|
||||||
|
|
||||||
echo "==> Compiling .mo files"
|
echo "==> Compiling .mo files"
|
||||||
./devtools/compile_translations.sh
|
./devtools/compile_translations.sh
|
||||||
|
Loading…
x
Reference in New Issue
Block a user