2011-03-13 06:05:19 +00:00
|
|
|
#!/bin/sh
|
2016-06-17 12:47:43 +00:00
|
|
|
|
2016-06-27 08:58:47 +00:00
|
|
|
# Let this be executed in the po/ subdir.
|
2016-04-18 03:39:07 +00:00
|
|
|
cd "$(dirname "$0")" || exit
|
2016-06-17 12:47:43 +00:00
|
|
|
|
|
|
|
echo "Updating translations via TP"
|
2011-03-13 06:05:19 +00:00
|
|
|
rsync -Lrtvz translationproject.org::tp/latest/nano/ .
|
2016-06-17 12:47:43 +00:00
|
|
|
|
|
|
|
# Are there now PO files that are not in git yet?
|
|
|
|
NEWSTUFF=$(git status --porcelain *.po | grep "^??")
|
|
|
|
|
2016-04-18 03:39:07 +00:00
|
|
|
if [ -n "${NEWSTUFF}" ]; then
|
2016-06-17 12:47:43 +00:00
|
|
|
echo "New languages found; updating LINGUAS"
|
|
|
|
echo "# List of available languages." >LINGUAS
|
|
|
|
echo $(printf '%s\n' *.po | LC_ALL=C sort | sed 's/\.po//g') >>LINGUAS
|
2011-03-13 06:05:19 +00:00
|
|
|
fi
|
2016-06-17 12:47:43 +00:00
|
|
|
|
2016-06-27 08:58:47 +00:00
|
|
|
echo "Regenerating POT file and remerging and recompiling PO files..."
|
|
|
|
make update-po
|