From 87fd9325345c3a7f23ed1807e994b20f459f5661 Mon Sep 17 00:00:00 2001 From: chansuke Date: Tue, 29 Oct 2024 00:19:11 +0900 Subject: [PATCH] Add checked out ref for `actions/checkout@v4` --- .github/workflows/golangci-lint.yml | 2 ++ .github/workflows/misspell.yml | 2 ++ .github/workflows/release.yml | 1 + .github/workflows/tests.yml | 2 ++ 4 files changed, 7 insertions(+) diff --git a/.github/workflows/golangci-lint.yml b/.github/workflows/golangci-lint.yml index 0e81b48..778759b 100644 --- a/.github/workflows/golangci-lint.yml +++ b/.github/workflows/golangci-lint.yml @@ -23,6 +23,8 @@ jobs: - name: Check out code into the Go module directory uses: actions/checkout@v4 + with: + ref: ${{ github.event.pull_request.head.sha }} - name: golangci-lint uses: golangci/golangci-lint-action@v6 diff --git a/.github/workflows/misspell.yml b/.github/workflows/misspell.yml index adfcc1f..dd78a83 100644 --- a/.github/workflows/misspell.yml +++ b/.github/workflows/misspell.yml @@ -23,6 +23,8 @@ jobs: - name: Check out code into the Go module directory uses: actions/checkout@v4 + with: + ref: ${{ github.event.pull_request.head.sha }} - name: Spellcheck run: | diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 0dc872f..cfd4e85 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -14,6 +14,7 @@ jobs: uses: actions/checkout@v4 with: fetch-depth: 0 + ref: ${{ github.event.pull_request.head.sha }} - name: Set up Go uses: actions/setup-go@v5 diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index a68420d..dd9cc08 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -23,6 +23,8 @@ jobs: - name: Check out code into the Go module directory uses: actions/checkout@v4 + with: + ref: ${{ github.event.pull_request.head.sha }} - name: Build run: go build ./...