I currently have a situation where I've got two branches and PRs open. They both branch from a broken commit (B) on master.
PR #1 (commit
C) fixes the breakage
PR #2 (commit
D) tweaks the bitbucket-pipelines.yml file, and is essentially unrelated to
My repo has a pipelines file with a
pull-requests: ** configuration to run the pipeline against a post-merge commit.
PR #1 and
PR #2 were both created from commit
PR #1, commit
C fixes the breakage and the has a green pipeline.
PR #2, the breakage is still present so the resulting pipeline of commit
D merged with
At some point later, both PRs were approved and
PR#1 was merged.
My state looks something like this:
C (pr #1) ↗ ↘ (pull request is merged to master) A -> B -----> E ↘ D (pr #2)
My question is this:
How can I run a new pipeline for
PR #2 against the result of merging
- If I RERUN the existing pipeline, it runs with the old state of the target branch (i.e. merges
B, and the pipeline fails as the breakage is still present)
- If I manually execute a pipeline for the branch with commit
D, using the
pull-requests: **configuration, no merge happens at all (essentially treating it as if it's not a pull-request pipeline at all)
I have some other options:
- Merge master (commit
E) into my branch and push the change
git commit --amendcommit
D'and force-push it
Instead, it would be great if there was some way to say "hey pipelines, run the pipeline for my PR against the latest state of the target branch". Perhaps a thing in the UI which shows up if the latest pipeline ran against an outdated commit on the target branch?