How to auto-merge Stash develop branch in feature (plan) branches in Bamboo
Asked by Pascal:

I'm trying to setup automatic merging of the development branch into a feature branch in Bamboo as described here: <https://confluence.atlassian.com/display/BAMBOO/Using+plan+branches#Usingplanbranches-Usingautomaticmerging>

However, I cannot seem to set this up, since our Git repository is Stash and Bamboo tells me (on the Branches tab of the build plan configuration): "Merging is disabled for this plan branch as the default repository 'Develop' is of type 'Stash', which does not support automatic merging.". This seems ultimately weird, as underlying is simply Git and merging seems to be available for Git repositories.

So my question is: can I really not achieve automatic merging with Stash or am I just overlooking something?


Answers:
author: rsperafico
body: Hello Pascal,

I am sorry for the delay on getting back to you.

Based on the screenshots you have provided, it seems Bamboo is using JGit as capability instead of Git. Please, go to "*Bamboo administration \>\> Build resources \>\> Server capabilities*" and make sure you have added Git as a Capability as per following:

bamboo.git.capability.png

If you find this answer useful, I would kindly ask you to accept it so the same will be visible to others who might be facing the same issue you have inquired.

Thank you for your understanding.

---

Kind regards,  
Rafael P. Sperafico  
Atlassian Support  
[](https://community.atlassian.com/t5/Bamboo-questions/How-to-auto-merge-Stash-develop-branch-in-feature-plan-branches/qaq-p/404603?attachment-id=8116){#link_1169158aee7d9c}  
[](/tnckb94959/attachments/tnckb94959/bamboo-questions/12713/1/bamboo.git.capability.png){#display_1169158aee7d9c_0}


author: Pascal
body: Hi Rafael,

That is "develop". Here a screenshot of that page and one of the branching model:

Settings.png

Branching_Model.png

Thanks,

Pascal  
[](https://community.atlassian.com/t5/Bamboo-questions/How-to-auto-merge-Stash-develop-branch-in-feature-plan-branches/qaq-p/404603?attachment-id=5461){#link_116915903d5ef6}  
[](/tnckb94959/attachments/tnckb94959/bamboo-questions/12712/1/Settings.png){#display_116915903d5ef6_0}  
[](https://community.atlassian.com/t5/Bamboo-questions/How-to-auto-merge-Stash-develop-branch-in-feature-plan-branches/qaq-p/404603?attachment-id=5462){#link_116915903d5ef6_0}  
[](/tnckb94959/attachments/tnckb94959/bamboo-questions/12712/2/Branching_Model.png){#display_116915903d5ef6_2}


author: rsperafico
body: Hello Pascal,

Thank you for all the information.

Could you let us know what is the Default Branch associated with your repository "Applications / IBE" in Stash, please? In can find this information under "*Repository \>\> Settings \>\> Repository details \>\> Default branch*"

---

Kind regards,  
Rafael P. Sperafico  
Atlassian Support


author: Pascal
body: We're using version 5.7.2. Here are some screen shots of our configuration:

Repositories.png

Branches.png

Triggers.png

Thanks for your help!  
[](https://community.atlassian.com/t5/Bamboo-questions/How-to-auto-merge-Stash-develop-branch-in-feature-plan-branches/qaq-p/404603?attachment-id=1464){#link_1169159bf2fa8f}  
[](/tnckb94959/attachments/tnckb94959/bamboo-questions/12710/1/Repositories.png){#display_1169159bf2fa8f_0}  
[](https://community.atlassian.com/t5/Bamboo-questions/How-to-auto-merge-Stash-develop-branch-in-feature-plan-branches/qaq-p/404603?attachment-id=1465){#link_1169159bf2fa8f_0}  
[](/tnckb94959/attachments/tnckb94959/bamboo-questions/12710/2/Triggers.png){#display_1169159bf2fa8f_2}  
[](https://community.atlassian.com/t5/Bamboo-questions/How-to-auto-merge-Stash-develop-branch-in-feature-plan-branches/qaq-p/404603?attachment-id=1466){#link_1169159bf2fa8f_1}  
[](/tnckb94959/attachments/tnckb94959/bamboo-questions/12710/3/Branches.png){#display_1169159bf2fa8f_4}


author: Krystian Brazulewicz
body: Which Bamboo version do you use? Can you please post the screenshot of your plan repository configuration?


Tags: bitbucket-server

git