This needs to actually force push the tag or you can end up in a bad state.

This commit is contained in:
Karl Matthias
2012-04-24 17:18:58 +01:00
parent ffa8baf1f4
commit 09b35efcc4
+1 -1
View File
@@ -64,7 +64,7 @@ module Capistrano
cdt.safe_run "git", "tag", "-a", cdt.git_tag_for(stage), "-m", "#{tag_user} deployed #{current_sha} to #{stage}"
if cdt.git_tag?(cdt.last_git_tag_for(stage))
cdt.safe_run "git", "tag", "-d", cdt.last_git_tag_for(stage)
cdt.safe_run "git", "push", "--tags" if cdt.has_remote?
cdt.safe_run "git", "push", "origin", ":refs/tags/#{cdt.last_git_tag_for(stage)}" if cdt.has_remote?
end
cdt.safe_run "git", "tag", "-a", cdt.last_git_tag_for(stage), "-m", "#{tag_user} deployed #{current_sha} to #{stage}"