Paste #wDx2piemISaYE4XnJJoM
=== modified file 'scripts/translators.sh'
| 1 | 1 | #!/bin/sh |
|---|---|---|
| 2 | 2 | |
| 3 | codename=vivid | |
| 3 | 4 | CURDIR=$(pwd)/po/ |
| 4 | 5 | |
| 5 | 6 | get_languages() { |
| … | ||
| 18 | 19 | for lang in $languages;do |
| 19 | 20 | mkdir -p $CURDIR/mo/$lang/LC_MESSAGES/ |
| 20 | 21 | msgfmt -o $CURDIR/mo/$lang/LC_MESSAGES/xubuntu-docs.mo $CURDIR/$lang.po |
| 21 | |
|
| 22 | translators=$(TEXTDOMAINDIR=$CURDIR/mo/ LANGUAGE=$lang gettext -d xubuntu-docs -s 'translator-credits' | \ | |
| 22 | 23 | sed -e 's@^ @\t<listitem><para>@' -e '/launchpad.net/s@$@)</para></listitem>@' \ |
| 23 | -e 's@https://launchpad.net/~@(@' -e /Launchpad\ Contributions/d -e /^translator-credits$/d | |
| 24 | done | sort | uniq | |
| 24 | -e 's@https://launchpad.net/~@(@' -e /Launchpad\ Contributions/d -e /^translator-credits$/d | sort -u) | |
| 25 | done | |
| 26 | if [ "$translators" = "" ];then | |
| 27 | echo "<listitem><para>Unable to parse translator data or data unavailable, see <ulink url=\"https://translations.launchpad.net/xubuntu-docs/$codename/+pots/desktop-guide/$lang/+details\">Launchpad</ulink></para></listitem>" | |
| 28 | else | |
| 29 | echo "$translators" | |
| 30 | fi | |
| 25 | 31 | echo "</itemizedlist>" |
| 26 | 32 | rm -rf $CURDIR/mo/ |
| 27 | 33 | } |