Class: SupportingCast::Generators::SunspotConfigGenerator

Inherits:
Rails::Generators::Base
  • Object
show all
Includes:
GeneratorHelpers
Defined in:
lib/generators/supporting_cast/sunspot_config_generator.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods included from GeneratorHelpers

#application_name, #development_port, #rails_root, #test_port

Instance Attribute Details

#envObject

Returns the value of attribute env.



11
12
13
# File 'lib/generators/supporting_cast/sunspot_config_generator.rb', line 11

def env
  @env
end

#portObject

Returns the value of attribute port.



11
12
13
# File 'lib/generators/supporting_cast/sunspot_config_generator.rb', line 11

def port
  @port
end

Instance Method Details

#default_portObject



13
14
15
# File 'lib/generators/supporting_cast/sunspot_config_generator.rb', line 13

def default_port
  8988
end

#sunspot_ymlObject



17
18
19
# File 'lib/generators/supporting_cast/sunspot_config_generator.rb', line 17

def sunspot_yml
  template 'sunspot.yml.erb', "config/sunspot.yml"
end