Permalink
Browse files

Generator::Base#usage takes an optional message argument which defaul…

…ts to Generator::Base#usage_message.

git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@3710 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
  • Loading branch information...
1 parent ba8a7bb commit a974b9e3c29e879d2c9247122dce958a5972419c @jeremy jeremy committed Feb 28, 2006
Showing with 4 additions and 2 deletions.
  1. +2 −0 railties/CHANGELOG
  2. +2 −2 railties/lib/rails_generator/options.rb
View
@@ -1,5 +1,7 @@
*SVN*
+* Generator::Base#usage takes an optional message argument which defaults to Generator::Base#usage_message. [Jeremy Kemper]
+
* Remove the extraneous AR::Base.threaded_connections setting from the webrick server. [Jeremy Kemper]
* Add integration test support to app generation and testing [Jamis Buck]
@@ -96,8 +96,8 @@ def parse!(args, runtime_options = {})
# Raise a usage error. Override usage_message to provide a blurb
# after the option parser summary.
- def usage
- raise UsageError, "#{@option_parser}\n#{usage_message}"
+ def usage(message = usage_message)
+ raise UsageError, "#{@option_parser}\n#{message}"
end
def usage_message

0 comments on commit a974b9e

Please sign in to comment.