Created
November 13, 2009 14:34
-
-
Save jwreagor/233859 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
set :git_tagging, true | |
set :tag_stamp, Time.now.strftime("%Y%m%d%H%M%S") | |
set :tag_name, ENV['TAG'] || "#{tag_stamp}-REL-#{rails_env}" | |
desc 'Git related recipes' | |
namespace :git do | |
desc 'pulls down submodules after performing a deployment' | |
task :submodules do | |
run "cd #{deploy_to}/current && | |
git submodule init && | |
git submodule update" | |
end | |
desc 'Tag the current branch for a release' | |
task :tag do | |
system "git tag -a -m 'Tagged for release on #{tag_stamp}' #{tag_name}" | |
system "git push --tags" | |
end | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment