Skip to content

Instantly share code, notes, and snippets.

@jellybob
Forked from anonymous/gist:874753
Created March 17, 2011 18:08
Show Gist options
  • Save jellybob/874816 to your computer and use it in GitHub Desktop.
Save jellybob/874816 to your computer and use it in GitHub Desktop.
#get the war files from the git repo
branch = "release-12"
bash "name_git_repo" do
user "username"
cwd "path/to/repo"
code "git checkout -b #{branch}-#{DateTime.now} origin/#{branch}"
action :nothing
end
git "/path/to/repo" do
repository "user@server:~/path/to/repo}"
reference branch
user "username"
action :sync
notifies :execute, resources(:bash => "name_git_repo")
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment