there is new tool for handling translation files. You can install it
using command
gem install i18n-translators-tools
This package brings you useful utility and library which can help you
to handle
locale files and translations in your Ruby projects. Offers also built-
in simple
console editor. Supported formats are YAML, Ruby, Gettext po, QT
Linguist TS and
Java Properties.
It can
– convert between various format (yml <=> rb <=> po <=> ts <=>
properties)
– merge
– statistics
– translate (built-in simple text translator)
Well, there is simple standalone web translator as a working example:
It is written using framework ramaze (I have sent it there because
this group is enlisted as a mailing-list for the i18n-library)
However, the scenario for using this tool is following:
In your application you just include backend
I18n::Backend::Simple.send(:include, I18n::Backend::Translator)
for your locales you need to have some default file (eg. default.yml
in eg. locale directory) and then you can use i18n-translate tool
for merging files. If you want to use PO files then you need include
also I18n::Backend::PO etc.
I also recomend to use fallbacks plugin.
I18n::Backend::Simple.send(:include, I18n::Backend::Fallbacks)
Some usage examples are also in README.md file:
This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.