lib/heroku_deploy/tasks.rb in heroku_deploy-0.1.4 vs lib/heroku_deploy/tasks.rb in heroku_deploy-0.1.5

- old
+ new

@@ -96,11 +96,11 @@ puts "Setup Complete!" puts "" end def staging - backup staging_app + backup staging_app unless no_backup puts "Deploying to Staging" merge "master", "staging" push_to 'staging', staging_app @@ -108,11 +108,11 @@ puts "Staging Deployed!" puts "" end def production - backup production_app + backup production_app unless no_backup puts "Deploying to Production" merge "staging", "production" push_to 'production', production_app @@ -147,11 +147,11 @@ puts "Going into maintenance mode" `heroku maintenance:on --app #{app}` - puts "Waiting for slug to re-compile..." + print "Waiting for slug to re-compile..." wait_for_maintenance_page( app ) puts "" puts "Pushing to #{app}" @@ -170,11 +170,10 @@ `heroku maintenance:off --app #{app}` end - def backup( app ) puts "" puts "Beginning Backup" timestamp = Time.now.strftime("%Y%m%d%H%M%S") old_bundle = `heroku bundles --app #{app}`.split.first @@ -220,8 +219,10 @@ def bundle_captured?( app ) `heroku bundles --app #{app}`.include?(" complete ") end - + def no_backup + ENV['BACKUP'] == "false" || ENV['backup'] == "false" + end end \ No newline at end of file