Hi
The scenario is as follows.
1. A user makes a pull request through the Bitbucket UI
2. The use clicks on the "Merge" button
3. The merge occurs and the bitbucket-pipeline gets exectued
4. the bitbucket-pipeline code tries to detect if this particular build got called because of merge.
I Tried detecting BITBUCKET_PR_ID variable but it doesn't work.
I tried counting the number of parents but there are times when there are 2 headers or less where there was an actual merge.
How would you recommend detecting a merge?
Below is the bitbucket pipeline code
G'day, @Jason Kim
Welcome to the community!
First, could you tell me why you must locate the merge commit in your pipeline build? I want to understand your goals so we are on the same page.
That said, when a merge occurs, it should trigger a pipeline build based on that merge, so you don't have to locate a specific commit or PR as a merge.
Also, I noticed that you have paid workspace so if you want to get a quicker response, I suggest raising a ticket directly to us at our Support portal
Regards,
Syahrul
Online forums and learning are now in one easy-to-use experience.
By continuing, you accept the updated Community Terms of Use and acknowledge the Privacy Policy. Your public name, photo, and achievements may be publicly visible and available in search engines.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.