Sha256: b73b205699b8644224796845a4913503731174b48836e5550de96ce6dcb97251

Contents?: true

Size: 565 Bytes

Versions: 11

Compression:

Stored size: 565 Bytes

Contents

task :restart do
  system "touch tmp/restart.txt"
  system "if which passenger-config >/dev/null; then passenger-config restart-app `pwd`; fi"
end

desc "Bootstrap project"
task :bootstrap do
  system "cp config/database.sample.yml config/database.yml" unless File.exist?('config/database.yml') or !File.exist?('config/database.sample.yml')
  invoke_task_if_exists "db:create:all"
  invoke_task_if_exists "db:migrate:all"
  if %w(staging production).include?(ENV["RAILS_ENV"])
    invoke_task_if_exists "assets:precompile"
  end
  Rake::Task["restart"].invoke
end

Version data entries

11 entries across 11 versions & 1 rubygems

Version Path
bard-rake-0.18.4 lib/bard/rake/bootstrap.rb
bard-rake-0.18.3 lib/bard/rake/bootstrap.rb
bard-rake-0.18.2 lib/bard/rake/bootstrap.rb
bard-rake-0.18.1 lib/bard/rake/bootstrap.rb
bard-rake-0.18.0 lib/bard/rake/bootstrap.rb
bard-rake-0.17.3 lib/bard/rake/bootstrap.rb
bard-rake-0.17.2 lib/bard/rake/bootstrap.rb
bard-rake-0.17.1 lib/bard/rake/bootstrap.rb
bard-rake-0.17.0 lib/bard/rake/bootstrap.rb
bard-rake-0.16.1 lib/bard/rake/bootstrap.rb
bard-rake-0.16.0 lib/bard/rake/bootstrap.rb