From 1a30ea7c6db865251f0d086c2df2755177037b79 Mon Sep 17 00:00:00 2001 From: Jeremy Olliver Date: Fri, 14 Mar 2014 14:39:43 +1300 Subject: [PATCH] Don't annotate on servers without source code --- lib/easy/deployment/capistrano.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/easy/deployment/capistrano.rb b/lib/easy/deployment/capistrano.rb index d18d811..4dd1791 100644 --- a/lib/easy/deployment/capistrano.rb +++ b/lib/easy/deployment/capistrano.rb @@ -108,7 +108,7 @@ def current_git_branch end desc "[internal] Annotate release into version.txt" - task :annotate_release do + task :annotate_release, :except => { :no_release => true } do git_revision = `git rev-parse #{branch} 2> /dev/null`.strip version_info = "Branch/Tag: #{branch}\\nRevision: #{git_revision}\\nDeployed To: #{stage}\\n\\nDeployed At: #{Time.now}\\nBy: #{`whoami`.chomp}\\n" run %Q(printf "#{version_info}" > #{release_path}/version.txt)