Sha256: 8eb7432da8b85ec8083118cd0058ca45726c170d8021f3aa565b2073673284c8

Contents?: true

Size: 435 Bytes

Versions: 4

Compression:

Stored size: 435 Bytes

Contents

namespace :check do
  desc 'Make sure local git is in sync with remote.'
  task :revision, roles: :web do
    unless `git rev-parse HEAD` == `git rev-parse origin/#{branch}`
      puts "WARNING: HEAD is not the same as origin/#{branch}"
      puts 'Run `git push` to sync changes.'
      exit
    end
  end
  before 'deploy', 'check:revision'
  before 'deploy:migrations', 'check:revision'
  before 'deploy:cold', 'check:revision'
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
recipes_matic-1.1.0 lib/generators/recipes_matic/templates/config/deploy/recipes/check.rb
recipes_matic-1.0.0 lib/generators/recipes_matic/templates/config/deploy/recipes/check.rb
recipes_matic-0.2.0 lib/generators/recipes_matic/templates/config/deploy/recipes/check.rb
recipes_matic-0.1.0 lib/generators/recipes_matic/templates/config/deploy/recipes/check.rb