I am working on an atlassian forge app that is supposed to merge changes through the release versions as in this discontinued feature https://confluence.atlassian.com/bitbucketserver0721/automatic-branch-merging-1115665735.html.
As far as I am concerned there is no way to merge anything without the use of pullrequests.
That's where the branch restrictions are coming in to play. Our workspace is configured in a way that only a few people are allowed to merge an pull request.
I was not able to find a way to get around the branch restrictions or add the app to the designated users. The only workaround i could think of was to delete the restriction and add it again after the merge is done.
Is there a better way to do this that i am not thinking of?
As far as I am concerned there is no way to merge anything without the use of pullrequests.
You can perform git operations using Forge, so you can perform a branch merge. However this is also subject to branch restrictions.
I was not able to find a way to get around the branch restrictions or add the app to the designated users.
While you can't add the app to the group, you might be able to add it to the branch restrictions. We do it on our app. It is not a Forge app, but it might work the same.
The only workaround i could think of was to delete the restriction and add it again after the merge is done.
You likely aware, but this has the side effect that for a few seconds users will be able to interact without the restrictions in place. The PR merge can take a while and you will likely only want to restore permissions once it is completed. Then you have multiple merges happening at the same time... it can get complicated fiddling with the restrictions.
Is there a better way to do this that i am not thinking of?
We provide a Bitbucket Cloud app, Flowie, which available via Atlassian marketplace and implements the automatic branch merging. The app manages the branch restrictions, has the cascade logic, which can be tweaked, and can also track the cascades - something that is not available in the original feature from Bitbucket.
If you have any questions get in touch via support@flowie.app and we will be glad to assist you!
Hi @Saxea _Flowie_
Thanks for the quick response.
I am not able to figure out how to add the app to a branch restriction.
Is there a special way to do that or should it be done the same way it is done for users?
If the second one is the case it might not be possible.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Yeah, same as users. I think you are right, and this is possibly related to BCLOUD-22400.
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.