Skip to content

Update golangci-lint and re-enable CI linting step #10

Update golangci-lint and re-enable CI linting step

Update golangci-lint and re-enable CI linting step #10

Workflow file for this run

name: Validate
on:
pull_request:
paths-ignore:
- "**.md"
- "channel.yaml"
- "install.sh"
- "tests/**"
- "!tests/e2e**"
- "!tests/docker**"
- ".github/**"
- "!.github/actions/**"
- "!.github/workflows/validate.yaml"
permissions:
contents: read
jobs:
validate:
name: Validate
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v6
- name: Set Go Version
run: |
source ./scripts/version.sh
{
echo "GOTOOLCHAIN=${VERSION_GOLANG/go}"
} >> "$GITHUB_ENV"
- name: Setup Go
uses: actions/setup-go@v6
with:
go-version: "${{ env.GOTOOLCHAIN }}"
- name: Lint
uses: golangci/golangci-lint-action@v9
with:
version: v2.7
args: "--new-from-merge-base ${{ github.base_ref }}"
- name: Lint (windows)
uses: golangci/golangci-lint-action@v9
with:
version: v2.7
args: "--new-from-merge-base ${{ github.base_ref }} ./pkg/... ./cmd/..."
env:
GOOS: "windows"
- name: Validate
run: ./scripts/validate
env:
SKIP_LINT: "true"
- name: Validate (windows)
run: ./scripts/validate
env:
SKIP_LINT: "true"
GOOS: "windows"