Class: Bulk::Generators::InstallGenerator

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

Class Method Summary collapse

Instance Method Summary collapse

Class Method Details

.source_rootObject



10
11
12
# File 'lib/generators/bulk/install/install_generator.rb', line 10

def self.source_root
  @source_root ||= File.expand_path(File.join(File.dirname(__FILE__), 'templates'))
end

Instance Method Details

#copy_app_bulk_application_resourceObject



19
20
21
# File 'lib/generators/bulk/install/install_generator.rb', line 19

def copy_app_bulk_application_resource
  template 'app/bulk/application_resource.rb'
end

#copy_initializers_bulk_apiObject



23
24
25
# File 'lib/generators/bulk/install/install_generator.rb', line 23

def copy_initializers_bulk_api
  template "config/initializers/bulk_api.rb"
end

#routes_entryObject



14
15
16
17
# File 'lib/generators/bulk/install/install_generator.rb', line 14

def routes_entry
  route 'bulk_routes "/api/bulk"'
  route 'mount Bulk::Sproutcore.new => "/_sproutcore"'
end