概要
Controllerの削除
サンプル
自動生成実行
※RSpec、Haml環境です。デフォルト構成ならTest,ERBが生成されます
$ rails d controller sample index
remove app/controllers/sample_controller.rb
route get "sample/index"
invoke haml
remove app/views/sample
remove app/views/sample/index.html.haml
invoke rspec
remove spec/controllers/sample_controller_spec.rb
remove spec/views/sample
remove spec/views/sample/index.html.haml_spec.rb
invoke helper
remove app/helpers/sample_helper.rb
invoke rspec
remove spec/helpers/sample_helper_spec.rb
invoke assets
invoke coffee
remove app/assets/javascripts/sample.js.coffee
invoke scss
remove app/assets/stylesheets/sample.css.scss