Not sure if it is a bug or I am missing something.
I am getting following error with rails edge.
(master)$ rails g controller glass --force
identical app/controllers/glass_controller.rb
invoke erb
exist app/views/glass
invoke test_unit
identical test/functional/glass_controller_test.rb
invoke helper
identical app/helpers/glass_helper.rb
invoke test_unit
identical test/unit/helpers/glass_helper_test.rb
invalid option: --force
Test::Unit automatic runner.
Usage: script/rails [options] [-- untouched arguments]
-r, --runner=RUNNER Use the given RUNNER.
(c[onsole], f[ox], g[tk], g[tk]2, t[k])
-n, --name=NAME Runs tests matching NAME.
(patterns may be used).
-t, --testcase=TESTCASE Runs tests in TestCases matching TESTCASE.
(patterns may be used).
-I, --load-path=DIR[:DIR...] Appends directory list to $LOAD_PATH.
-v, --verbose=[LEVEL] Set the output level (default is verbose).
(s[ilent], p[rogress], n[ormal], v[erbose])
-- Stop processing options so that the
remaining options will be passed to the
test.
-h, --help Display this help.
Deprecated options:
--console Console runner (use --runner).
--gtk GTK runner (use --runner).
--fox Fox runner (use --runner).
Help says --force should be a valid option.
$ rails g controller -h
Usage:
rails generate controller NAME [action action] [options]
Options:
[--helper] # Indicates when to generate helper
# Default: true
[--skip-namespace] # Skip namespace (affects only isolated applications)
-t, [--test-framework=NAME] # Test framework to be invoked
# Default: test_unit
-e, [--template-engine=NAME] # Template engine to be invoked
# Default: erb
Runtime options:
-q, [--quiet] # Supress status output
-f, [--force] # Overwrite files that already exist
-s, [--skip] # Skip files that already exist
-p, [--pretend] # Run but do not make any changes
Description:
Stubs out a new controller and its views. Pass the controller name, either
CamelCased or under_scored, and a list of views as arguments.
To create a controller within a module, specify the controller name as a
path like 'parent_module/controller_name'.
This generates a controller class in app/controllers and invokes helper,
template engine and test framework generators.
Example:
`rails generate controller CreditCard open debit credit close`
Credit card controller with URLs like /credit_card/debit.
Controller: app/controllers/credit_card_controller.rb
Functional Test: test/functional/credit_card_controller_test.rb
Views: app/views/credit_card/debit.html.erb [...]
Helper: app/helpers/credit_card_helper.rb
Test::Unit automatic runner.
Usage: script/rails [options] [-- untouched arguments]
-r, --runner=RUNNER Use the given RUNNER.
(c[onsole], f[ox], g[tk], g[tk]2, t[k])
-n, --name=NAME Runs tests matching NAME.
(patterns may be used).
-t, --testcase=TESTCASE Runs tests in TestCases matching TESTCASE.
(patterns may be used).
-I, --load-path=DIR[:DIR...] Appends directory list to $LOAD_PATH.
-v, --verbose=[LEVEL] Set the output level (default is verbose).
(s[ilent], p[rogress], n[ormal], v[erbose])
-- Stop processing options so that the
remaining options will be passed to the
test.
-h, --help Display this help.
Deprecated options:
--console Console runner (use --runner).
--gtk GTK runner (use --runner).
--fox Fox runner (use --runner).