Skip to content

Instantly share code, notes, and snippets.

@omkz
Forked from AshikNesin/rails-skip.md
Created January 30, 2023 23:33
Show Gist options
  • Save omkz/78c82163fd42bfad556f73871111f362 to your computer and use it in GitHub Desktop.
Save omkz/78c82163fd42bfad556f73871111f362 to your computer and use it in GitHub Desktop.
Rails generator controller without tests, assets & helpers

Configuring application.rb

To turn off without having to add options:

# application.rb
config.generators.assets = false
config.generators.helper = false

While Generating Controller

Try using --no- followed by optionname:

rails generate controller home index --no-helper --no-assets --no-controller-specs --no-view-specs

via StackOverflow

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment