Class: ForestRails::InstallGenerator

Inherits:
Rails::Generators::Base
  • Object
show all
Defined in:
lib/generators/forest_rails/install_generator.rb

Instance Method Summary collapse

Instance Method Details

#installObject



7
8
9
10
11
12
13
# File 'lib/generators/forest_rails/install_generator.rb', line 7

def install
  jwt_signing_key = ask('What\'s your project secret key?')
  route("mount ForestRails::Engine => '/forest'")
  initializer 'forest_rails.rb' do
    "ForestRails.jwt_signing_key = '#{jwt_signing_key}'"
  end
end