diff options
author | Prem Sichanugrist <s@sikachu.com> | 2010-12-31 23:54:49 +0700 |
---|---|---|
committer | Aaron Patterson <aaron.patterson@gmail.com> | 2011-01-01 11:58:09 -0800 |
commit | fd1daf9a8e751aaa700a18d6ac9c48b6f016ea7c (patch) | |
tree | 0e0a57530e2bfbc7cff9cc2b58a50c6179c6713d /railties/lib/rails | |
parent | 5c7fd8766586dba42fba6fc738a733175dd9d46b (diff) | |
download | rails-fd1daf9a8e751aaa700a18d6ac9c48b6f016ea7c.tar.gz rails-fd1daf9a8e751aaa700a18d6ac9c48b6f016ea7c.tar.bz2 rails-fd1daf9a8e751aaa700a18d6ac9c48b6f016ea7c.zip |
Make sure that generator's default banner is showing its namespace
This will make `rails g rspec:install --help` shows "rails generate rspec:install [options]" and not "rails generate install [options]"
Diffstat (limited to 'railties/lib/rails')
-rw-r--r-- | railties/lib/rails/generators/base.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/railties/lib/rails/generators/base.rb b/railties/lib/rails/generators/base.rb index f97f3db588..131eb6ff6f 100644 --- a/railties/lib/rails/generators/base.rb +++ b/railties/lib/rails/generators/base.rb @@ -274,7 +274,7 @@ module Rails # Use Rails default banner. # def self.banner - "rails generate #{generator_name} #{self.arguments.map{ |a| a.usage }.join(' ')} [options]" + "rails generate #{namespace.sub(/^rails:/,'')} #{self.arguments.map{ |a| a.usage }.join(' ')} [options]".gsub(/\s+/, ' ') end # Sets the base_name taking into account the current class namespace. |