Skip to content

Commit

Permalink
ci: prevent merge of stacked PRs
Browse files Browse the repository at this point in the history
  • Loading branch information
TheButlah committed May 19, 2024
1 parent 57ad3bd commit f75057c
Showing 1 changed file with 18 additions and 0 deletions.
18 changes: 18 additions & 0 deletions .github/workflows/stacked-prs.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
name: Stacked PRs
on:

pull_request:
types: [opened, edited, synchronize, reopened]
pull_request_target:
types: [opened, edited, synchronize, reopened]

jobs:
prevent_merge_of_stacked_pr:
runs-on: ubuntu-latest
steps:
- name: Check that base is "main"
run: |
echo "${GITHUB_BASE_REF}"
if [[ "${GITHUB_BASE_REF}" != "main" ]]; then
exit 1;
fi

0 comments on commit f75057c

Please sign in to comment.