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

0 vote

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
How to earn badges on the Atlassian Community

How to earn badges on the Atlassian Community

Badges are a great way to show off community activity, whether you’re a newbie or a Champion.

Learn more
Community showcase
Published May 18, 2017 in Bamboo

FAQ: How to Upgrade Bamboo Server

Bamboo 5.9 will no longer be supported after June 12, 2017. What does this mean? As part of our End of Life policy, Atlassian supports major versions for two years after the first major iteratio...

1,819 views 0 6
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