diff options
author | Jeremy Kemper <jeremy@bitsweat.net> | 2006-02-28 20:58:29 +0000 |
---|---|---|
committer | Jeremy Kemper <jeremy@bitsweat.net> | 2006-02-28 20:58:29 +0000 |
commit | a974b9e3c29e879d2c9247122dce958a5972419c (patch) | |
tree | 312822b0eab5ffdbbd85ace8c0914ddaff247792 /railties/lib | |
parent | ba8a7bbf4d3d0fba36b07699f583dc84448a4b0f (diff) | |
download | rails-a974b9e3c29e879d2c9247122dce958a5972419c.tar.gz rails-a974b9e3c29e879d2c9247122dce958a5972419c.tar.bz2 rails-a974b9e3c29e879d2c9247122dce958a5972419c.zip |
Generator::Base#usage takes an optional message argument which defaults to Generator::Base#usage_message.
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@3710 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
Diffstat (limited to 'railties/lib')
-rw-r--r-- | railties/lib/rails_generator/options.rb | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/railties/lib/rails_generator/options.rb b/railties/lib/rails_generator/options.rb index df9737f13f..fe80f8340d 100644 --- a/railties/lib/rails_generator/options.rb +++ b/railties/lib/rails_generator/options.rb @@ -96,8 +96,8 @@ module Rails # 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 |