diff options
author | Silvan Mosberger <contact@infinisil.com> | 2024-01-21 22:47:10 +0100 |
---|---|---|
committer | Silvan Mosberger <contact@infinisil.com> | 2024-01-21 22:47:10 +0100 |
commit | 0825957f5441f5892a123998730af53fa2056f00 (patch) | |
tree | f27470d7fc148f53cba661c3e6af0b0e1043f0a3 /.github/workflows/check-by-name.yml | |
parent | f36cf57e73adad6145c66a9671a75e2a814f1c3e (diff) |
workflows/check-by-name: Trigger on base branch changes
Not doing this can cause CI to report a misleading result when it wasn't retriggered after a base branch change.
Diffstat (limited to '.github/workflows/check-by-name.yml')
-rw-r--r-- | .github/workflows/check-by-name.yml | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/.github/workflows/check-by-name.yml b/.github/workflows/check-by-name.yml index 4295c64758485..94875e67b6497 100644 --- a/.github/workflows/check-by-name.yml +++ b/.github/workflows/check-by-name.yml @@ -8,7 +8,15 @@ name: Check pkgs/by-name # see pkgs/test/nixpkgs-check-by-name/scripts/README.md on: # Using pull_request_target instead of pull_request avoids having to approve first time contributors - pull_request_target + pull_request_target: + # This workflow depends on the base branch of the PR, + # but changing the base branch is not included in the default trigger events, + # which would be `opened`, `synchronize` or `reopened`. + # Instead it causes an `edited` event, so we need to add it explicitly here + # While `edited` is also triggered when the PR title/body is changed, + # this PR action is fairly quick, and PR's don't get edited that often, + # so it shouldn't be a problem + types: [opened, synchronize, reopened, edited] permissions: # We need this permission to cancel the workflow run if there's a merge conflict |