Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

How to run pipelines when a new Pull Request get created?

zulhfreelancer September 23, 2017

Hi,

 

Here is my bitbucket-pipelines.yml file: https://gist.github.com/anonymous/f0327773953f086bc4990784b16e63a7

 

I'm aware that I can use branch workflow to tell Bitbucket Pipelines to only run the build and run my tests when a specific branch get new Git push from developer and I'm currently using it.

 

How to run the Bitbucket Pipelines when a developer submit a Pull Request from his/her branch to a branch specified inside the `branches` block of my bitbucket-pipelines.yml file?

 

For example, how to run the Bitbucket Pipelines when John submit his `awesome_branch` PR to `development` branch?

 

Expected behaviour:

- when John push his commits to `awesome_branch` to Bitbucket = I don't want Bitbucket Pipelines to run

- when John submit PR and set `awesome_branch` as source branch and `development` as target branch = I want Bitbucket Pipelines to run

 

I also noticed that Bitbucket Pipelines offer 'manual trigger'.

 

Assuming 'run Bitbucket Pipelines when a new PR get submitted' feature is not available yet, how do call the manual/custom pipeline from Bitbucket API?

 

I'm thinking to create a bash script to call the manual/custom pipeline but I couldn't find how to do it via Bitbucket API.

1 answer

0 votes
zulhfreelancer September 23, 2017

I also noticed that Bitbucket Pipelines offer 'manual trigger'.

 

Assuming 'run Bitbucket Pipelines when a new PR get submitted' feature is not available yet, how do call the manual/custom pipeline from Bitbucket API?

 

I'm thinking to create a bash script to call the manual/custom pipeline but I couldn't find how to do it via Bitbucket API.

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events