I18n generator
This plugin generates a config file and locale files for Rails 2.2 i18n feature.
Installation
As a gem
% sudo gem install amatsuda-i18n_generators -s gems.github.com
As a Rails plugin
% ./script/plugin install git://github.com/amatsuda/i18n_generators.git
Example
% ./script/generate i18n ja-JP (de-AT, pt-BR, etc.)
This will generate following files.
config/initializers/i18n_config.rb
lib/locale/action_view_ja-JP.yml
lib/locale/active_record_ja-JP.yml
lib/locale/active_support_ja-JP.yml
Requirement
This plugin requires gettext gem ( rubyforge.org/projects/gettext/ ) and sufficient speed of the Internet connection.
Caution
Current version of this plugin is very very very very roughly implemented just for experiment. Every time you execute the generate command, the plugin connects to the Unicode CLDR website and scrapes the huge amount of its contents. Please be careful not to harm your network environment and CLDR website by running this plugin too many times.
Todo
-
More accurate format tranlation.
-
Download the XML data file via CLDR website and store in tmp directory.
-
Merging with the existing locale file.
-
Currency sign
Copyright © 2008 Akira Matsuda, released under the MIT license