i need declarative pipeline syntax for trigger new pull request on successfully build

24 views
Skip to first unread message

Atul Sharma

unread,
Jul 24, 2019, 7:18:54 PM7/24/19
to Jenkins Users
i have pipeline code and i am struggling to write syntax in my declarative pipeline steps whenever build result will success from source branch pipeline should create new pull requests on bitbucket.. i don't find any way to do it .. please help to write
syntax

lesterp

unread,
Jul 25, 2019, 2:09:52 PM7/25/19
to Jenkins Users
Have you looked into the Bitbucket Branch Source Plugin ?  That plugin can scan your repo for branches and PRs (that you can filter) and will build and report on them accordingly.

Ivan Fernandez Calvo

unread,
Jul 25, 2019, 3:35:30 PM7/25/19
to Jenkins Users
You could use a post condition and some tool to create PR on BitBucket
https://jenkins.io/doc/book/pipeline/syntax/#post
https://www.npmjs.com/package/cmd-bitbucket
Reply all
Reply to author
Forward
0 new messages