Skip to content
Browse files

Merge remote branch 'mikel/master'

  • Loading branch information...
2 parents 639e044 + 1ae543a commit 9b033d14b240ae1ae8b1486af1d0afa8ae2a1ec6 @jeremy jeremy committed
Showing with 5 additions and 2 deletions.
  1. +2 −2 activerecord/lib/active_record/railties/databases.rake
  2. +3 −0 railties/lib/rails/commands.rb
View
4 activerecord/lib/active_record/railties/databases.rake
@@ -28,8 +28,8 @@ namespace :db do
desc 'Create the database defined in config/database.yml for the current Rails.env - also makes test database if in development mode'
task :create => :load_config do
- # Make the test database at the same time as the development one
- if Rails.env == 'development'
+ # Make the test database at the same time as the development one, if it exists
+ if Rails.env.development? && ActiveRecord::Base.configurations['test']
create_database(ActiveRecord::Base.configurations['test'])
end
create_database(ActiveRecord::Base.configurations[Rails.env])
View
3 railties/lib/rails/commands.rb
@@ -59,6 +59,9 @@
require 'rails/commands/runner'
require ENV_PATH
+
+when '--version', '-v'
+ puts "Rails #{Rails::VERSION::STRING}"
when '--help', '-h'
puts HELP_TEXT
when '--version', '-v'

0 comments on commit 9b033d1

Please sign in to comment.
Something went wrong with that request. Please try again.