Specifying the source code revision to build

What is the proper way to configure plans in Bamboo when you wish to build specific source code revisions? I have a custom task plugin which lets me specify whether to build the latest code or takes an argument for a specific revision.

Should I create a "master plan" which always builds the latest source code, and then duplicate it whenever I want to have a plan that builds a specific revision? I would change the custom task plugin's revision parameter for each duplicated plan.

1 answer

1 accepted

Accepted Answer
0 votes

You don't really need a custom task for this, I think. You could create a script task that takes a parameter that is defined as a Bamboo variable. The script task would just update the directory to the specified revision, e.g. for Subversion that would be: svn up -r $1 . You can then run the build as a paramterised build and override the variable any time you want, or clone the plan aroudn and override the variable per plan.

Parameterized builds sound like what I need, thanks.

We are currently using scripts while the plugin is being developed. We want to provide a simple GUI for a variety of Perforce tasks (like syncing, checking out files, and branching) without forcing the user to read the command line documentation. A custom task GUI is just easier and safer for non-admins to use.

Suggest an answer

Log in or Sign up to answer
Community showcase
Published Monday in Jira Ops

Jira Ops Early Access Program Update #1: Announcing our next feature and a new integration

Thanks for signing up for Jira Ops! I’m Matt Ryall, leader for the Jira Ops product team at Atlassian. Since this is a brand new product, we’ll be delivering improvements quickly and sharing updates...

482 views 0 9
Read article

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you