jenkinsci / jenkinsci/github-branch-source-plugin

[JENKINS-68299] PRs auto-rebuilds - PRs still start running after merge to master

Open
#1,394 0 comments 0 reactions 0 assignees View on GitHub
component:github-branch-source-plugin component:multibranch-scan-webhook-trigger-plugin imported-jira-issue priority:critical resolution:unresolved
Dominant language
Java
Stars
217
Forks
398
Avg merge
30m
Merged PRs (30d)
1

Description

Hello, I am facing an interesting issue: I have 3 open PRs , so when I make a merge to master the remaining 2 start to run automatically , but I dont want that behavior. The better approach for me is to run pipeline only  on PR when is created AND after PR is merged(to master) to run on master.

I saw ticket JENKINS-37491 where it said to: Install Basic Branch Build Strategies plugin and add the "Change Requests" with "Ignore rebuilding merge branches when only the target branch changed" selected to your build strategies... but that behavior stop pipeline to run on master branch and I dont want that. Also the setting Regular Branches" its appear with the state "Not Build"  when a PR is created , this case also is not good for me

So  is any chance to stop trigger remaining PRs after a merge to master is made?   

---
Originally reported by flaviuslinus, imported from: PRs auto-rebuilds - PRs still start running after merge to master


  • assignee: igalg
  • status: Open
  • priority: Critical
  • component(s): github-branch-source-plugin, multibranch-scan-webhook-trigger-plugin
  • resolution: Unresolved
  • votes: 0
  • watchers: 1
  • imported: 2025-12-02

Raw content of original issue

Hello, I am facing an interesting issue: I have 3 open PRs , so when I make a merge to master the remaining 2 start to run automatically , but I dont want that behavior. The better approach for me is to run pipeline only  on PR when is created AND after PR is merged(to master) to run on master.

I saw ticket JENKINS-37491 where it said to: Install Basic Branch Build Strategies plugin and add the "Change Requests" with "Ignore rebuilding merge branches when only the target branch changed" selected to your build strategies... but that behavior stop pipeline to run on master branch and I dont want that. Also the setting Regular Branches" its appear with the state "Not Build"  when a PR is created , this case also is not good for me

So  is any chance to stop trigger remaining PRs after a merge to master is made?   

environment

```
github-branch-source latest

jenkins latest
```

2 attachments

- [Screenshot 2022-04-18 184322.png](https://issues.jenkins.io/secure/attachment/57717/Screenshot%202022-04-18%20184322.png)
> ![Screenshot 2022-04-18 184322.png](https://issues.jenkins.io/secure/attachment/57717/Screenshot%202022-04-18%20184322.png)
- [Screenshot 2022-04-18 193241.png](https://issues.jenkins.io/secure/attachment/57716/Screenshot%202022-04-18%20193241.png)
> ![Screenshot 2022-04-18 193241.png](https://issues.jenkins.io/secure/attachment/57716/Screenshot%202022-04-18%20193241.png)

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.