Class: Fileboost::Generators::InstallGenerator

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

Class Method Summary collapse

Instance Method Summary collapse

Class Method Details

.source_rootObject



8
9
10
# File 'lib/generators/fileboost/install_generator.rb', line 8

def self.source_root
  @source_root ||= File.expand_path("templates", __dir__)
end

Instance Method Details

#create_initializer_fileObject



12
13
14
# File 'lib/generators/fileboost/install_generator.rb', line 12

def create_initializer_file
  template "fileboost.rb", "config/initializers/fileboost.rb"
end

#show_readmeObject



16
17
18
# File 'lib/generators/fileboost/install_generator.rb', line 16

def show_readme
  readme "INSTALL" if behavior == :invoke
end