Deploy a Specific Mercurial Branch with Capistrano

This is mostly a reminder for me as I couldn’t find an example online (I have notoriously bad Google-Fu) about deploying a different branch to the one you have set in your Capistrano deploy.rb file.

The command is very simple:

cap -s branch=branch_name deploy

I wanted to deploy to a staging environment so I did:

cap -s branch=branch_name staging deploy

It really is as simple as that.

Advertisements
This entry was posted in Programming, Ruby, Ruby on Rails, Uncategorized and tagged , , . Bookmark the permalink.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s