Problem
- Translation = boring
- Translation time = €
- Cannot be automated
Solution
- Translate everything automatically
- Correct any errors
Magic
- Use Google Translate API
- Remove Namespaces (Movie|Name = Nombre )
- Preserve String replacements (hello %{name} = Olla %{name} )
Install
http://github.com/grosser/autolang
Copy autolang.rake OR checkout into lib/tasks(if you are using rails, otherwise place it where rake can find it)
(Non-ruby?: install ruby + rubygems + rake-gem)
Usage
rake autolang:translate L=es POT_FILE=x.pot
Example Output
(commandline output, translations are written to "es.po") Translating... register registro -------------------------------------------------------------------------------- login inicio de sesión -------------------------------------------------------------------------------- Your DVD is being built and will be finished soon. Su DVD se está construyendo y será terminado pronto. -------------------------------------------------------------------------------- Invitation sent to %{email} Invitación enviada a %{email} ....
One thought on “Automatic Translations with Autolang for Gettext”