diff --git a/.github/workflows/coverage-comment.yaml b/.github/workflows/coverage-comment.yaml index 0332610..829dbda 100644 --- a/.github/workflows/coverage-comment.yaml +++ b/.github/workflows/coverage-comment.yaml @@ -17,7 +17,7 @@ jobs: steps: - name: Download coverage artifacts - uses: actions/github-script@v8 + uses: actions/github-script@v9 with: script: | const artifacts = await github.rest.actions.listWorkflowRunArtifacts({ @@ -64,7 +64,7 @@ jobs: - name: Get PR number id: pr - uses: actions/github-script@v8 + uses: actions/github-script@v9 with: script: | const { data: pullRequests } = await github.rest.pulls.list({ @@ -83,7 +83,7 @@ jobs: - name: Comment PR with coverage if: steps.pr.outputs.result != 'null' - uses: actions/github-script@v8 + uses: actions/github-script@v9 with: script: | const fs = require('fs'); diff --git a/.golangci.yaml b/.golangci.yaml index fb98ac3..9f6a3d6 100644 --- a/.golangci.yaml +++ b/.golangci.yaml @@ -52,6 +52,9 @@ linters: linters: - gosec settings: + govet: + disable: + - inline errcheck: exclude-functions: - (io.Closer).Close diff --git a/.mise-tasks/lint b/.mise-tasks/lint index 65521a4..b458803 100755 --- a/.mise-tasks/lint +++ b/.mise-tasks/lint @@ -3,10 +3,11 @@ set -euo pipefail echo "๐Ÿ” Running linting checks..." -GOLANGCI_VERSION=$(golangci-lint --version | sed -nE 's/.*golangci-lint has version ([0-9.]+).*/\1/p') +GOLANGCI_LINT=(mise exec -- golangci-lint) +GOLANGCI_VERSION=$("${GOLANGCI_LINT[@]}" --version | sed -nE 's/.*golangci-lint has version ([0-9.]+).*/\1/p') GOLANGCI_VERSION=${GOLANGCI_VERSION:-unknown} echo "๐Ÿงน Running golangci-lint v${GOLANGCI_VERSION} (includes go vet)..." -golangci-lint run +"${GOLANGCI_LINT[@]}" run echo "๐Ÿ›ก๏ธ Running nilaway..." NILAWAY_BIN=$(command -v nilaway || true) diff --git a/.mise.toml b/.mise.toml index 32ae94e..9db54f2 100644 --- a/.mise.toml +++ b/.mise.toml @@ -1,18 +1,19 @@ [tools] +golangci-lint = "2.12.2" gotestsum = "latest" [tasks.setup-vscode-symlinks] description = "Create VSCode symlinks for tools not automatically handled by mise-vscode" run = [ "mkdir -p .vscode/mise-tools", - "ln -sf $(mise exec golangci-lint@2.7.2 -- which golangci-lint) .vscode/mise-tools/golangci-lint", + "ln -sf $(mise exec -- which golangci-lint) .vscode/mise-tools/golangci-lint", ] [hooks] postinstall = [ "ln -sf ./AGENTS.md ./CLAUDE.md", "git submodule update --init --recursive", - "go install github.com/golangci/golangci-lint/v2/cmd/golangci-lint@v2.7.2", + "mise install golangci-lint", "mise run setup-vscode-symlinks", "go install go.uber.org/nilaway/cmd/nilaway@8ad05f0", ]