Sha256: 7472ff2d000dec65836e8d3fe5ab7d0a98c200c20f924cd7d30d10d7cd0c9b14

Contents?: true

Size: 552 Bytes

Versions: 7

Compression:

Stored size: 552 Bytes

Contents

class StateGenerator < Rails::Generator::NamedBase #:nodoc:
  def manifest
    record do |m|
      # Check for class naming collisions.
      m.class_collisions class_path, "#{class_name}State"

      # Controller, helper, views, and test directories.
      m.directory File.join('app/states', class_path)

      # Controller class, functional test, and helper class.
      m.template 'state.rb',
                  File.join('app/states',
                            class_path,
                            "#{file_name}_state.rb")


    end
  end
end

Version data entries

7 entries across 7 versions & 2 rubygems

Version Path
shattered-0.3.3 lib/rails_generator/generators/components/state/state_generator.rb
shattered-0.3.2 lib/rails_generator/generators/components/state/state_generator.rb
shattered-0.4.0.1 lib/rails_generator/generators/components/state/state_generator.rb
shattered-0.4 lib/rails_generator/generators/components/state/state_generator.rb
shattered-0.5.0.1 lib/rails_generator/generators/components/state/state_generator.rb
shattered_ruby-0.5.1 lib/rails_generator/generators/components/state/state_generator.rb
shattered_ruby-0.5.0.2 lib/rails_generator/generators/components/state/state_generator.rb