I am using the active_admin gem in my Rails 3 application, which has as a dependency inherited_resources. I am somewhat of a newb and would rather avoid the black box qualities of inherited_resources for my own controllers, however, when I run the default rails g scaffold command, the controllers that are generated are inheriting from inherited_resources. I know that I can manually override this by inheriting from ApplicationController, however, I would like to be able to generate the default rails scaffolds if possible.
Asked
Active
Viewed 1,659 times
5
-
found it. found a reference to the -c command line argument for 'rails generate scaffold'. To force rails to use the normal scaffold generator, add -c=scaffold_generator to the end of the command – jpw Jan 19 '12 at 01:59
2 Answers
12
-c=scaffold_controller
or add this to config/application.rb
config.generators do |g|
g.scaffold_controller "scaffold_controller"
end

nigelr
- 391
- 4
- 7
0
Also noted in an issue thread over at github: https://github.com/josevalim/inherited_resources/issues/195

tamouse
- 2,169
- 1
- 19
- 26