Why does rails scaffold generator is simply ignoring my config/iniatilizers/inflections.rb? -


i'm using rails 3.2 ruby 2.1

i put code config/initializers/inflections.rb :

  activesupport::inflector.inflections |inflect|     inflect.irregular 'pub_type_contributeur', 'pub_types_contributeurs'     inflect.irregular 'pubtypecontributeur', 'pubtypescontributeurs'   end 

when test rails console works :

rails console [deprecated] i18n.enforce_available_locales default true in future. if want skip validation of locale can set i18n.enforce_available_locales = false avoid message. loading development environment (rails 3.2.16) 2.1.0 :001 > "attendance".pluralize  => "attendances"  2.1.0 :002 > "pub_type_contributeur".pluralize  => "pub_types_contributeurs"  2.1.0 :003 > exit 

but when use standard generator, ignore inflection :

rails generate scaffold pub_type_contribueur nom:text -p [deprecated] i18n.enforce_available_locales default true in future. if want skip validation of locale can set i18n.enforce_available_locales = false avoid message.       invoke  active_record       create    db/migrate/20141112191424_create_pub_type_contribueurs.rb       create    app/models/pub_type_contribueur.rb       invoke    rspec       create      spec/models/pub_type_contribueur_spec.rb       invoke      factory_girl       create        spec/factories/pub_type_contribueurs.rb       invoke  resource_route        route    resources :pub_type_contribueurs       invoke  scaffold_controller       create    app/controllers/pub_type_contribueurs_controller.rb       invoke    haml       create      app/views/pub_type_contribueurs       create      app/views/pub_type_contribueurs/index.html.haml       create      app/views/pub_type_contribueurs/edit.html.haml       create      app/views/pub_type_contribueurs/show.html.haml       create      app/views/pub_type_contribueurs/new.html.haml       create      app/views/pub_type_contribueurs/_form.html.haml       invoke    rspec       create      spec/controllers/pub_type_contribueurs_controller_spec.rb       create      spec/views/pub_type_contribueurs/edit.html.haml_spec.rb       create      spec/views/pub_type_contribueurs/index.html.haml_spec.rb       create      spec/views/pub_type_contribueurs/new.html.haml_spec.rb       create      spec/views/pub_type_contribueurs/show.html.haml_spec.rb       create      spec/routing/pub_type_contribueurs_routing_spec.rb       invoke    helper       create      app/helpers/pub_type_contribueurs_helper.rb       invoke      rspec       create        spec/helpers/pub_type_contribueurs_helper_spec.rb       invoke  assets       invoke    coffee       invoke    scss       invoke  scss 

what doing wrong ?

ok time work late , misspell name... sorry bad, forgot "t" letter.

my command incorrect :

rails generate scaffold pub_type_contribueur nom:text --no-stylesheets -p 

this correct 1 :

rails generate scaffold pub_type_contributeur nom:text --no-stylesheets -p 

Comments

Popular posts from this blog

c++ - QTextObjectInterface with Qml TextEdit (QQuickTextEdit) -

javascript - angular ng-required radio button not toggling required off in firefox 33, OK in chrome -

xcode - Swift Playground - Files are not readable -