Skip to content

Commit fc5b10c

Browse files
committed
fix(ci): use fetch-depth: 0 for super-linter checkout
Super-linter needs the full git history to resolve GITHUB_BEFORE_SHA (the previous commit SHA). With fetch-depth: 1 it fails with: 'The SHA_REFERENCE reference doesn't exist in this Git repository'
1 parent 7bb39d4 commit fc5b10c

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

.github/workflows/action-super-linter.yml

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -27,9 +27,8 @@ jobs:
2727
- name: Checkout code
2828
uses: actions/checkout@v6
2929
with:
30-
# Shallow clone reduces transient fetch failures (HTTP 500) from GitHub.
31-
# We lint the whole codebase instead of relying on git history.
32-
fetch-depth: 1
30+
# Full clone required so super-linter can resolve GITHUB_BEFORE_SHA.
31+
fetch-depth: 0
3332
fetch-tags: false
3433
persist-credentials: false
3534

0 commit comments

Comments
 (0)