GitHub Sale: sign up for any paid plan this week and pay nothing until January 1, 2009!  [ hide ]

public
Fork of wycats/merb-plugins
Description: Merb Plugins: Even more modules to hook up your Merb installation
Homepage: http://www.merbivore.com
Clone URL: git://github.com/auser/merb-plugins.git
added better error message when a database can't be created
mattetti (author)
Tue Mar 11 22:41:33 -0700 2008
commit  4024820c9f4b1832c65ad4f605513ad0ae5ae012
tree    1f8bcf00d93362124d5d15442ba36a9772b633d7
parent  0e934d504f64ee6c17c3ce02729855071067b67d
...
35
36
37
38
 
39
40
41
...
35
36
37
 
38
39
40
41
0
@@ -35,7 +35,7 @@ namespace :db do
0
             ActiveRecord::Base.establish_connection(config)
0
             puts "MySQL #{config[:database]} database successfully created"
0
           rescue
0
- $stderr.puts "Couldn't create database for #{config.inspect}, charset: #{@charset}, collation: #{@collation} (if you set the charset manually, make sure you have a matching collation)"
0
+ $stderr.puts "Couldn't create database for #{config.inspect}, charset: #{config[:charset] || @charset}, collation: #{config[:collation] || @collation} (if you set the charset manually, make sure you have a matching collation)"
0
           end
0
         when 'postgresql'
0
           `createdb "#{config[:database]}" -E utf8`

Comments

    No one has commented yet.