Browse Source

fix(ci): fetch full history in details-check so base ref diff works (#4940)

The create-matrix job runs 'git diff origin/${base_ref}...HEAD' to
detect which servers a PR touches, but actions/checkout defaults to a
shallow single-branch fetch, so origin/develop does not exist in the
runner and the diff fails with 'ambiguous argument' on every PR that
reaches this job. Set fetch-depth: 0 so the base ref is available.
pull/4941/head
Daniel Gibbs 1 day ago
committed by GitHub
parent
commit
d402330737
No known key found for this signature in database GPG Key ID: B5690EEEBB952194
  1. 5
      .github/workflows/details-check.yml

5
.github/workflows/details-check.yml

@ -27,6 +27,11 @@ jobs:
steps:
- name: Checkout
uses: actions/checkout@v6
with:
# Full history so the base branch ref is available for the
# `git diff origin/<base>...HEAD` comparison below (a shallow
# checkout has no origin/<base> and the diff fails).
fetch-depth: 0
- name: Detect targeted servers (PR only)
id: targeted

Loading…
Cancel
Save