Project

General

Profile

HowTo translate Redmine in your own language » History » Revision 17

Revision 16 (Azamat Hackimov, 2010-09-06 13:59) → Revision 17/27 (Azamat Hackimov, 2010-09-06 14:05)

h1. HowTo translate Redmine in your own language 

 Redmine can easily be translated in any language. 

 There are a few things to translate: 

 # The main lang file, located at source:/trunk/config/locales in current trunk 
 # The calendar lang file, located in source:trunk/public/javascripts/calendar/lang 
 # The wiki toolbar lang file, located in source:trunk/public/javascripts/jstoolbar/lang 

 Say you want to translate Redmine in Finnish (@fi@ as defined in the "IANA Language Subtag Registry":http://www.iana.org/assignments/language-subtag-registry): 

 # Copy @/config/locales/en.yml@ to @/config/locales/fi.yml@. @/config/locales/fi.yml@ and translate every strings this file contains. 
 # Copy @/public/javascripts/calendar/lang/calendar-en.js@ to @/public/javascripts/calendar/lang/calendar-fi.js@. @/public/javascripts/calendar/lang/calendar-fi.js@ and translate every strings this file contains (mainly day and month names). 
 # Copy @/public/javascripts/jstoolbar/lang/jstoolbar-en.js@ to @/public/javascripts/jstoolbar/lang/jstoolbar-fi.js@. @/public/javascripts/jstoolbar/lang/jstoolbar-fi.js@ and translate the strings. 
 # Translate every string in these files. 
 # Test your translation with command <pre>rake test</pre> If you get errors related to locales, you must fix them. 
 # Submit your translation "here":http://www.redmine.org/projects/redmine/issues/new?tracker_id=3 (as plain file or patch, login required). 
 # Wait until your Issue will be fixed. 
 # GOTO 4 if needed. 

 h2. Restrictions 

 *All these files must be UTF-8 encoded.* Do not use HTML entities in translated strings. 

 Check that your files not have BOM (Byte-order mark). BOM can be removed with command: 

 <pre> 
 awk '{if(NR==1)sub(/^\xef\xbb\xbf/, "");print}' < oldfile > newfile 
 </pre> 

 You can submit your translation "here":http://www.redmine.org/projects/redmine/issues/new?tracker_id=3 (login required) if you want it to be added to the next release. 

 As of 2009-02-21, *only updates based on the new translation files* (found in @/config/locales@) *should be submitted.* 

 h2. Updates to the language files 

 File @en.yml@ acts as the main language file. You can check if it has new strings by running: 
 <pre>rake locales:update</pre> 

 This copies the new strings to other translation files (with the English translation as default value).