Skip to content

Commit 5757aab

Browse files
Fix Linter error
1 parent 3bcb3c5 commit 5757aab

1 file changed

Lines changed: 3 additions & 6 deletions

File tree

.github/workflows/linter.yml

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -18,14 +18,11 @@ jobs:
1818
- name: Checkout Code
1919
uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4
2020
with:
21-
ref: ${{ github.head_ref }}
21+
# Check out the head of the PR specifically
22+
ref: ${{ github.event.pull_request.head.sha }}
2223
fetch-depth: 0
2324
persist-credentials: false
2425

25-
- name: Set lint SHA from checked-out HEAD
26-
id: set_lint_sha
27-
run: echo "sha=$(git rev-parse HEAD)" >> "$GITHUB_OUTPUT"
28-
2926
- name: Fetch base branch for diff
3027
run: git fetch --no-tags --prune origin "+refs/heads/${{ github.event.pull_request.base.ref }}:refs/remotes/origin/${{ github.event.pull_request.base.ref }}"
3128

@@ -34,5 +31,5 @@ jobs:
3431
env:
3532
VALIDATE_ALL_CODEBASE: false
3633
DEFAULT_BRANCH: ${{ github.event.pull_request.base.ref }}
37-
GITHUB_HEAD_REF: ${{ github.head_ref }}
34+
GITHUB_SHA: ${{ github.event.pull_request.head.sha }}
3835
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

0 commit comments

Comments
 (0)