]> granicus.if.org Git - ejabberd/commitdiff
Provide header with latin-1 encoding in translations to work with Erlang/OTP R17
authorBadlop <badlop@process-one.net>
Wed, 12 Mar 2014 16:26:27 +0000 (17:26 +0100)
committerBadlop <badlop@process-one.net>
Wed, 12 Mar 2014 16:26:27 +0000 (17:26 +0100)
contrib/extract_translations/prepare-translation.sh

index fcc58cb27c0f6c7843a57e6e4441f82ca1cc7714..56f9992472f823409d447a5e91e3302461fbdaef 100755 (executable)
@@ -230,7 +230,8 @@ extract_lang_po2msg ()
        msgattrib $PO_PATH --translated --no-fuzzy --no-obsolete --no-location --no-wrap | grep "^msg" | tail --lines=+3 >$MS_PATH
        grep "^msgid" $PO_PATH.ms | sed 's/^msgid //g' >$MSGID_PATH
        grep "^msgstr" $PO_PATH.ms | sed 's/^msgstr //g' >$MSGSTR_PATH
-       paste $MSGID_PATH $MSGSTR_PATH --delimiter=, | awk '{print "{" $0 "}."}' | sort -g >$MSGS_PATH
+       echo "%% -*- coding: latin-1 -*-" >$MSGS_PATH
+       paste $MSGID_PATH $MSGSTR_PATH --delimiter=, | awk '{print "{" $0 "}."}' | sort -g >>$MSGS_PATH
 
        rm $MS_PATH
        rm $MSGID_PATH