mirror of https://github.com/PCSX2/pcsx2.git
i18n: * add poedit metadata after generating the pot files. It seems to be useful after all :p
git-svn-id: http://pcsx2.googlecode.com/svn/trunk@4399 96395faa-99c1-11dd-bbfe-3dabce05a288
This commit is contained in:
parent
cff78af50e
commit
0ea9dbc2c5
|
@ -81,6 +81,23 @@ echo "Generate $TER_POT"
|
||||||
xgettext --keyword=$TER_KEY1 --keyword=$TER_KEY2 --keyword=$TER_KEY3 $GENERAL_OPTION $input_files --output=$TER_POT
|
xgettext --keyword=$TER_KEY1 --keyword=$TER_KEY2 --keyword=$TER_KEY3 $GENERAL_OPTION $input_files --output=$TER_POT
|
||||||
sed --in-place $TER_POT --expression=s/charset=CHARSET/charset=UTF-8/
|
sed --in-place $TER_POT --expression=s/charset=CHARSET/charset=UTF-8/
|
||||||
|
|
||||||
|
######################################################################
|
||||||
|
# Add poedit metadata
|
||||||
|
# It eases poedit for translators
|
||||||
|
######################################################################
|
||||||
|
# Metadata example
|
||||||
|
# "X-Poedit-KeywordsList: pxE_dev;pxDt\n"
|
||||||
|
# "X-Poedit-SourceCharset: utf-8\n"
|
||||||
|
# "X-Poedit-Basepath: trunk\\\n"
|
||||||
|
# "X-Poedit-SearchPath-0: pcsx2\n"
|
||||||
|
# "X-Poedit-SearchPath-1: common\n"
|
||||||
|
# Normally "...Content-Transfer-Encoding..." is the end of the header. Use it as anchor to place poedit metadata after
|
||||||
|
COMMON_META="\"X-Poedit-SourceCharset: utf-8\\\n\"\n\"X-Poedit-Basepath: trunk\\\\\\\\\\\n\"\n\"X-Poedit-SearchPath-0: pcsx2\\\n\"\n\"X-Poedit-SearchPath-1: common\\\n\""
|
||||||
|
sed --in-place $MAIN_POT --expression=s/'\"Content-Transfer-Encoding: 8bit\\n\"'/"\"Content-Transfer-Encoding: 8bit\\\n\"\n\"X-Poedit-KeywordsList: ${MAIN_KEY1};${MAIN_KEY2}\\\n\"\n${COMMON_META}"/
|
||||||
|
sed --in-place $DEV_POT --expression=s/'\"Content-Transfer-Encoding: 8bit\\n\"'/"\"Content-Transfer-Encoding: 8bit\\\n\"\n\"X-Poedit-KeywordsList: ${DEV_KEY1};${DEV_KEY2}\\\n\"\n${COMMON_META}"/
|
||||||
|
sed --in-place $ICO_POT --expression=s/'\"Content-Transfer-Encoding: 8bit\\n\"'/"\"Content-Transfer-Encoding: 8bit\\\n\"\n\"X-Poedit-KeywordsList: ${ICO_KEY1}\\\n\"\n${COMMON_META}"/
|
||||||
|
sed --in-place $TER_POT --expression=s/'\"Content-Transfer-Encoding: 8bit\\n\"'/"\"Content-Transfer-Encoding: 8bit\\\n\"\n\"X-Poedit-KeywordsList: ${TER_KEY1};${TER_KEY2};${TER_KEY3}\\\n\"\n${COMMON_META}"/
|
||||||
|
|
||||||
######################################################################
|
######################################################################
|
||||||
# Automatically align the .po to the new pot file
|
# Automatically align the .po to the new pot file
|
||||||
######################################################################
|
######################################################################
|
||||||
|
|
Loading…
Reference in New Issue