diff options
author | Philip Arndt <parndt@gmail.com> | 2011-01-28 04:16:11 +0800 |
---|---|---|
committer | José Valim <jose.valim@gmail.com> | 2011-01-29 16:51:38 +0800 |
commit | 36f570dbd230d34c24f8e56310224af0cdf9e5cf (patch) | |
tree | bdb1792b02dab9f19623e5715fc2504fc5f0651d /railties/lib/rails | |
parent | 740bc35d328b262669e70065cd30e6b354456f26 (diff) | |
download | rails-36f570dbd230d34c24f8e56310224af0cdf9e5cf.tar.gz rails-36f570dbd230d34c24f8e56310224af0cdf9e5cf.tar.bz2 rails-36f570dbd230d34c24f8e56310224af0cdf9e5cf.zip |
Apply exit code 1 when commands don't succeed so that other libraries can properly detect the failure.
Diffstat (limited to 'railties/lib/rails')
-rw-r--r-- | railties/lib/rails/commands.rb | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/railties/lib/rails/commands.rb b/railties/lib/rails/commands.rb index 46363d7921..f015b33e18 100644 --- a/railties/lib/rails/commands.rb +++ b/railties/lib/rails/commands.rb @@ -62,6 +62,7 @@ when 'application', 'runner' when 'new' puts "Can't initialize a new Rails application within the directory of another, please change to a non-Rails directory first.\n" puts "Type 'rails' for help." + exit(false) when '--version', '-v' ARGV.unshift '--version' @@ -91,4 +92,5 @@ In addition to those, there are: All commands can be run with -h for more information. EOT + exit(false) end |