Class: GitRubyDeploy::Generators::InstallGenerator

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

Instance Method Summary collapse

Instance Method Details

#copy_filesObject

Generator Code. Remember this is just suped-up Thor so methods are executed in order



20
21
22
23
# File 'lib/generators/git_ruby_deploy/install_generator.rb', line 20

def copy_files
  copy_file 'config/controllers/git_deploy_controller.rb', 'app/controllers/git_deploy_controller.rb'
  inject_into_file 'config/routes.rb',"\tget '/deploy', to: 'git_deploy#deploy'\n", :before => /^end/
end