1
0
Fork 0
mirror of https://github.com/rails/rails.git synced 2022-11-09 12:12:34 -05:00

script/console uses RAILS_ENV environment variable if present. Closes #2932.

git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@3083 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
This commit is contained in:
Jeremy Kemper 2005-11-18 07:33:28 +00:00
parent ae76e22731
commit 97d5f4acdf
2 changed files with 3 additions and 1 deletions

View file

@ -1,5 +1,7 @@
*SVN*
* script/console uses RAILS_ENV environment variable if present. #2932 [Blair Zajac <blair@orcaware.com>
* Windows: eliminate the socket option in database.yml. #2924 [Wayne Vucenic <waynev@gmail.com>]
* Eliminate nil from newly generated logfiles. #2927 [Blair Zajac <blair@orcaware.com>]

View file

@ -12,7 +12,7 @@ libs = " -r irb/completion"
libs << " -r #{RAILS_ROOT}/config/environment"
libs << " -r console_sandbox" if options[:sandbox]
ENV['RAILS_ENV'] = ARGV.first || 'development'
ENV['RAILS_ENV'] = ARGV.first || ENV['RAILS_ENV'] || 'development'
if options[:sandbox]
puts "Loading #{ENV['RAILS_ENV']} environment in sandbox."
puts "Any modifications you make will be rolled back on exit."