##// END OF EJS Templates
Merged r9755 from trunk....
Merged r9755 from trunk. git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/branches/1.4-stable@9757 e93f8b46-1217-0410-a6f0-8f06a7374b81

File last commit:

r9164:3db1fa6b839b
r9574:3883d5e2db4f
Show More
redmine_plugin_generator.rb
32 lines | 1.2 KiB | text/x-ruby | RubyLexer
/ lib / generators / redmine_plugin / redmine_plugin_generator.rb
Jean-Philippe Lang
Merged hooks branch @ r1785 into trunk....
r1785 class RedminePluginGenerator < Rails::Generator::NamedBase
attr_reader :plugin_path, :plugin_name, :plugin_pretty_name
Toshi MARUYAMA
remove trailing white-spaces from lib/generators/redmine_plugin/redmine_plugin_generator.rb...
r9097
Jean-Philippe Lang
Merged hooks branch @ r1785 into trunk....
r1785 def initialize(runtime_args, runtime_options = {})
super
@plugin_name = "redmine_#{file_name.underscore}"
@plugin_pretty_name = plugin_name.titleize
@plugin_path = "vendor/plugins/#{plugin_name}"
end
Toshi MARUYAMA
remove trailing white-spaces from lib/generators/redmine_plugin/redmine_plugin_generator.rb...
r9097
Jean-Philippe Lang
Merged hooks branch @ r1785 into trunk....
r1785 def manifest
record do |m|
m.directory "#{plugin_path}/app/controllers"
m.directory "#{plugin_path}/app/helpers"
m.directory "#{plugin_path}/app/models"
m.directory "#{plugin_path}/app/views"
m.directory "#{plugin_path}/db/migrate"
m.directory "#{plugin_path}/lib/tasks"
m.directory "#{plugin_path}/assets/images"
m.directory "#{plugin_path}/assets/javascripts"
m.directory "#{plugin_path}/assets/stylesheets"
m.directory "#{plugin_path}/lang"
Eric Davis
Added the Rails i18n language file to the plugin generator....
r2685 m.directory "#{plugin_path}/config/locales"
Jean-Philippe Lang
Merged hooks branch @ r1785 into trunk....
r1785 m.directory "#{plugin_path}/test"
Toshi MARUYAMA
remove trailing white-spaces from lib/generators/redmine_plugin/redmine_plugin_generator.rb...
r9097
Eric Davis
Renamed the .rb files in the plugin_generator to end in .erb. The .rb was...
r1947 m.template 'README.rdoc', "#{plugin_path}/README.rdoc"
m.template 'init.rb.erb', "#{plugin_path}/init.rb"
Eric Davis
Added the Rails i18n language file to the plugin generator....
r2685 m.template 'en_rails_i18n.yml', "#{plugin_path}/config/locales/en.yml"
Eric Davis
Renamed the .rb files in the plugin_generator to end in .erb. The .rb was...
r1947 m.template 'test_helper.rb.erb', "#{plugin_path}/test/test_helper.rb"
Jean-Philippe Lang
Merged hooks branch @ r1785 into trunk....
r1785 end
end
end