Class: EnumerateIt::Generators::EnumGenerator

Inherits:
Rails::Generators::NamedBase
  • Object
show all
Defined in:
lib/generators/enumerate_it/enum/enum_generator.rb

Instance Method Summary collapse

Instance Method Details

#create_enumerate_itObject



18
19
20
# File 'lib/generators/enumerate_it/enum/enum_generator.rb', line 18

def create_enumerate_it
  template 'enumerate_it.rb', File.join('app/enumerations', "#{singular_name}.rb")
end

#create_localeObject



13
14
15
# File 'lib/generators/enumerate_it/enum/enum_generator.rb', line 13

def create_locale
  template 'locale.yml', File.join('config/locales', "#{singular_name}.yml")
end