mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-04-28 21:08:04 +03:00
Split gettextize script into two
When building DolphinWX using cmake, msgmerge will run on the .po files, updating the formatting of them if they aren't already in the exact format that msgmerge uses. This means that running msgmerge on all the .po files is necessary before committing any updates to the .po files, because otherwise unstaged changes are going to appear whenever anyone tries to build that commit using cmake. The translation syncing scripts that were used by delroth and Parlane did so by invoking `cmake` and then `make translations`, but that isn't a good solution for people who sync translations on Windows (i.e. me). This commit uncomments some existing code for running msgmerge on all the .po files, and places that code in a new script. Now, translation syncing scripts just have to call that script before committing, instead of using msgmerge directly or using cmake. I'm not sure why the script was called gettextize to begin with. gettextize is the name of a gettext executable that doesn't seem to be related to what our gettextize script did.
This commit is contained in:
parent
a8606f5d13
commit
6425fa28ab
2 changed files with 17 additions and 9 deletions
16
Languages/update-source-strings.sh
Executable file
16
Languages/update-source-strings.sh
Executable file
|
@ -0,0 +1,16 @@
|
|||
#!/bin/bash
|
||||
|
||||
# This script updates the dolphin-emu.pot file to match the strings in
|
||||
# the source code.
|
||||
|
||||
cd ${0/update-source-strings.sh/}/..
|
||||
SRCDIR=Source
|
||||
find $SRCDIR -name '*.cpp' -o -name '*.h' -o -name '*.c' | \
|
||||
xgettext -d dolphin-emu -s --keyword=_ --keyword=wxTRANSLATE --keyword=SuccessAlertT \
|
||||
--keyword=PanicAlertT --keyword=PanicYesNoT --keyword=AskYesNoT --keyword=CriticalAlertT \
|
||||
--keyword=GetStringT --keyword=_trans --keyword=tr --keyword=QT_TR_NOOP \
|
||||
--add-comments=i18n -p ./Languages/po -o dolphin-emu.pot -f - --package-name="Dolphin Emulator"
|
||||
|
||||
sed -i "s/SOME DESCRIPTIVE TITLE\./Translation of dolphin-emu.pot to LANGUAGE/" Languages/po/dolphin-emu.pot
|
||||
sed -i "s/YEAR THE PACKAGE'S COPYRIGHT HOLDER/2003-2013/" Languages/po/dolphin-emu.pot
|
||||
sed -i "s/license as the PACKAGE package/license as the dolphin-emu package/" Languages/po/dolphin-emu.pot
|
Loading…
Add table
Add a link
Reference in a new issue