Skip to content

Instantly share code, notes, and snippets.

@Frost
Created August 6, 2012 08:32
Show Gist options
  • Save Frost/3272296 to your computer and use it in GitHub Desktop.
Save Frost/3272296 to your computer and use it in GitHub Desktop.
Select git branch to deploy with capistrano
server 'staging.domain.tld', :app, :web, :db, :primary => true
set :branch do
default_tag = "master"
tag = Capistrano::CLI.ui.ask "What tag/branch do you want to deploy? [#{default_tag}] "
tag = default_tag if tag.empty?
tag
end
set :rails_env, 'staging'
set :keep_releases, 2
set :port, 2222
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment