git: ignore the l10n stuff
[trojita.git] / Messages.sh
blob98723b411e6a5e8f58a0f678d232f57534ee69a0
1 #! /bin/bash
3 # xgettext-generated .po files use different context than QObject::tr.
4 # The generated files use something like a file name while QObject::tr expects
5 # class names. This approach works.
7 rm -f "${podir}/trojita.ts"
8 lupdate -silent -recursive src/ -ts "${podir}/trojita.ts"
9 ts2po --progress=none --pot "${podir}/trojita.ts" "${podir}/trojita_common.pot"
10 rm "${podir}/trojita.ts"
12 # ts2po puts class names into source reference comments (#:)
13 # instead of into extracted comments (#.),
14 # and does not extract source references at all.
15 # So convert source reference comments into extracted comments.
16 sed -i 's/^#:/#./' "${podir}/trojita_common.pot"