Hi Guys,
This is my first post. Hope i get a quick response.
What i have now is:-
a build plan which run unit test with every commit pushed in feature/* branch
What i need is
I want to create a plan which get executes only when PR is created and merge is blocked until build passes.
Im really stuggling to find out correct solution.
Any help is really appreciated.
Thanks
Supra
Hello Supra,
Welcome to Atlassian community.
A build plan which run unit test with every commit pushed in feature/* branch - This is the expected behaviour as you have trigger enabled on Bamboo and it will build the plan with each commit so this is expected, if you don't want to trigger this with each build then remove the trigger and probably set some other trigger like a scheduled trigger where frequency would be low.
Coming to your other question
I want to create a plan which get executes only when PR is created and merge is blocked until build passes.
Here you can use the concept of plan branches, whenever a PR is created in Bitbucket Bamboo will create a new plan branch automatically and will build it. This plan will automatically get disabled once the PR is merged successfully.
Create a plan and link it to the repository on which PR will be created and then on this plan you can enable branches as shown below, whenever a PR is created it will create a new plan branch on this plan and automatic build will start on it.
Read more about it at Using plan branches , you can use the below options from Branches tab on your plan
I am not yet sure on you ask regarding Merging, are you talking automatic Merging from Bamboo or manual PR merge in Bitbucket or any other repo
Regards,
Shashank Kumar
Thanks for ur quick reply.
my second question is the one im trying to solve it.
So just now i did a commit and added below logic in a feature/* branch. It did triggered the build which u mentioned as above as default behaviour
branches:
create: for-pull-request
In order to stop where should i go to remove the trigger, as shown below i cannot remove trigger.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I cannot edit this. What permission should i have?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I was able to sort the issue now the plan branch looks as it needs to be. However, i deleted the PR and recreated a new PR didnt work, what am i missing?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
So when you recreated the new PR, new plan branches are not created in Bamboo?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.