Class: Accountly::InstallGenerator
- Inherits:
-
Rails::Generators::Base
- Object
- Rails::Generators::Base
- Accountly::InstallGenerator
- Includes:
- Rails::Generators::Migration
- Defined in:
- lib/generators/accountly/install_generator.rb
Instance Attribute Summary collapse
-
#session_name ⇒ Object
Returns the value of attribute session_name.
-
#user_name ⇒ Object
Returns the value of attribute user_name.
Instance Method Summary collapse
- #create_config_files ⇒ Object
- #create_locales ⇒ Object
- #create_migration ⇒ Object
- #create_views ⇒ Object
- #setup_routes ⇒ Object
Instance Attribute Details
#session_name ⇒ Object
Returns the value of attribute session_name.
8 9 10 |
# File 'lib/generators/accountly/install_generator.rb', line 8 def session_name @session_name end |
#user_name ⇒ Object
Returns the value of attribute user_name.
8 9 10 |
# File 'lib/generators/accountly/install_generator.rb', line 8 def user_name @user_name end |
Instance Method Details
#create_config_files ⇒ Object
23 24 25 |
# File 'lib/generators/accountly/install_generator.rb', line 23 def create_config_files end |
#create_locales ⇒ Object
18 19 20 21 |
# File 'lib/generators/accountly/install_generator.rb', line 18 def create_locales template "config/locales/de.yml", "config/locales/de.accountly.yml" template "config/locales/en.yml", "config/locales/en.accountly.yml" end |
#create_migration ⇒ Object
31 32 33 |
# File 'lib/generators/accountly/install_generator.rb', line 31 def create_migration migration_template 'db/migrate/add_new_email_to_users.rb', "db/migrate/add_new_email_to_users.rb" end |
#create_views ⇒ Object
14 15 16 |
# File 'lib/generators/accountly/install_generator.rb', line 14 def create_views directory "views", "app/views/accountly" end |
#setup_routes ⇒ Object
27 28 29 |
# File 'lib/generators/accountly/install_generator.rb', line 27 def setup_routes route "mount Accountly::Engine => '/account', :as => 'accountly_engine'" end |