MainDocumentationCommunitySyndicationOhlohPowered by |
Translating Smuxi into other Languages
Before You StartPlease make sure the language you want to translate is not translated yet! Here a list of existing and finshed translations:
Please also check if it's not in SVN already, which you can do here. Started but not finished or complete translations:
Step 1: SVN checkoutFirst you need a SVN checkout using this command: svn co svn://svn.qnetp.net/smuxi/smuxi/trunk smuxi-svn Step 2: Initialize PO filesNow you need to initialize the PO files for the new language in each po-* directory:
cd smuxi-svn/po-Engine/ msginit cd ../po-Engine-IRC/ msginit cd ../po-Frontend-GNOME/ msginit cd ../po-Frontend-GNOME-IRC/ msginit Step 3: Translate PO filesNow you can open each $LANG.po file and start translating all message strings. Don't forget to update the "Last-Translator" to your name and e-mail address. Also change "charset=CHARSET" to "charset=UTF-8" and use a UTF-8 editor like gedit. ($LANG being your language code, like "de" for german, "es" for spanish etc.) Now you need to tell the build-system that there is a new translation file. Add $LANG to all po-*/LINGUAS files. Step 4: Create PatchAfter you translated all POT files, you need to generate a patch so I can apply it to the SVN repository. For that run the following commands in the smuxi-svn directory: cd smuxi-svn/ svn add po-*/$LANG.po svn diff > smuxi-$LANG.patch Step 5: Test TranslationIf you want to test your translation first in the real application, you need to compile the .po files to .mo and copy them into $app-dir/locale/$LANG/LC_MESSAGES/$POT-FILENAME.mo Step 5.1: Compile PO Filescd smuxi-svn/ ./autogen.sh make If you can't get ./autogen.sh to work because you don't have all libraries installed or available, you can also compile the PO files by hand like this: cd smuxi-svn/ msgfmt po-Engine/$LANG.po -o po-Engine/$LANG.mo msgfmt po-Engine-IRC/$LANG.po -o po-Engine-IRC/$LANG.mo (repeat for all po-*/$LANG.po files) Step 5.2: Copy MO FilesAllright now all PO files are compiled into MO files, so copy them into the right place like this: cd smuxi-svn/ cp po-Engine/$LANG.mo $app-dir/locale/$LANG/LC_MESSAGES/smuxi-engine.mo cp po-Engine-IRC/$LANG.mo $app-dir/locale/$LANG/LC_MESSAGES/smuxi-engine-irc.mo cp po-Frontend-GNOME/$LANG.mo $app-dir/locale/$LANG/LC_MESSAGES/smuxi-frontend-gnome.mo $app-dir is the application directory of smuxi which can be /usr/lib/smuxi or /opt/smuxi depending where you installed it. Step 5.3: Start SmuxiNow start smuxi and check your all message string if the translations all fit. Step 6: Submit TranslationWhen you are happy with the translation you can send me that patch via email or submit it as a trac ticket! Thank you very much for your translation in advance! |