mirror of
https://github.com/rails/rails.git
synced 2022-11-09 12:12:34 -05:00
Cleanup task for informing about hstore
This commit is contained in:
parent
fa265346a9
commit
1235b630fe
1 changed files with 3 additions and 6 deletions
|
@ -119,12 +119,9 @@ namespace :postgresql do
|
|||
%x( createdb -E UTF8 -T template0 #{config['arunit']['database']} )
|
||||
%x( createdb -E UTF8 -T template0 #{config['arunit2']['database']} )
|
||||
|
||||
# prepare hstore
|
||||
version = %x( createdb --version ).strip.gsub(/(.*)(\d\.\d\.\d)$/, "\\2")
|
||||
%w(arunit arunit2).each do |db|
|
||||
if version < "9.1.0"
|
||||
puts "Please prepare hstore data type. See http://www.postgresql.org/docs/9.0/static/hstore.html"
|
||||
end
|
||||
# notify about preparing hstore
|
||||
if %x( createdb --version ).strip.gsub(/(.*)(\d\.\d\.\d)$/, "\\2") < "9.1.0"
|
||||
puts "Please prepare hstore data type. See http://www.postgresql.org/docs/9.0/static/hstore.html"
|
||||
end
|
||||
end
|
||||
|
||||
|
|
Loading…
Reference in a new issue