diff options
author | Piotr Sarnacki <drogus@gmail.com> | 2010-11-15 13:09:39 -0600 |
---|---|---|
committer | José Valim <jose.valim@gmail.com> | 2010-11-16 00:04:35 +0100 |
commit | bf176e9c7a1aa46b021384b91f4f9ec9a1132c0f (patch) | |
tree | 6da60c8933c2bfabae073ff245dc3c5ce0730ba2 /railties/lib/rails/commands.rb | |
parent | b0665345f85e4b7f3b3367ee36fa205e7ff78d12 (diff) | |
download | rails-bf176e9c7a1aa46b021384b91f4f9ec9a1132c0f.tar.gz rails-bf176e9c7a1aa46b021384b91f4f9ec9a1132c0f.tar.bz2 rails-bf176e9c7a1aa46b021384b91f4f9ec9a1132c0f.zip |
Do not allow to use plugin_new generator directly, you should use Usage:
rails new APP_PATH [options]
Options:
-G, [--skip-git] # Skip Git ignores and keeps
-r, [--ruby=PATH] # Path to the Ruby binary of your choice
# Default: /Users/drogus/.rvm/rubies/ruby-1.8.7-p302/bin/ruby
-b, [--builder=BUILDER] # Path to an application builder (can be a filesystem path or URL)
[--edge] # Setup the application with Gemfile pointing to Rails repository
[--dev] # Setup the application with Gemfile pointing to your Rails checkout
[--skip-gemfile] # Don't create a Gemfile
-d, [--database=DATABASE] # Preconfigure for selected database (options: mysql/oracle/postgresql/sqlite3/frontbase/ibm_db)
# Default: sqlite3
-O, [--skip-active-record] # Skip Active Record files
-m, [--template=TEMPLATE] # Path to an application template (can be a filesystem path or URL)
-J, [--skip-prototype] # Skip Prototype files
-T, [--skip-test-unit] # Skip Test::Unit files
Runtime options:
-s, [--skip] # Skip files that already exist
-p, [--pretend] # Run but do not make any changes
-f, [--force] # Overwrite files that already exist
-q, [--quiet] # Supress status output
Rails options:
-v, [--version] # Show Rails version number and quit
-h, [--help] # Show this help message and quit
Description:
The 'rails new' command creates a new Rails application with a default
directory structure and configuration at the path you specify.
Example:
rails new ~/Code/Ruby/weblog
This generates a skeletal Rails installation in ~/Code/Ruby/weblog.
See the README in the newly created application to get going. command
Diffstat (limited to 'railties/lib/rails/commands.rb')
-rw-r--r-- | railties/lib/rails/commands.rb | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/railties/lib/rails/commands.rb b/railties/lib/rails/commands.rb index c8a33c1266..de5d876c18 100644 --- a/railties/lib/rails/commands.rb +++ b/railties/lib/rails/commands.rb @@ -14,6 +14,9 @@ case command when 'generate', 'destroy', 'plugin' if command == "plugin" && ARGV.first == "new" require "rails/commands/plugin_new" + elsif command == 'generate' && ARGV.first == "plugin_new" + puts "This generator should not be used directly as a generator. You should use `rails plugin new` command instead" + exit(1) else require APP_PATH Rails.application.require_environment! |