Skip to content

Update lint.yml #586

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 5 commits into from
Feb 19, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
25 changes: 14 additions & 11 deletions .github/workflows/lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,21 +3,24 @@ on:
push:
pull_request:

permissions:
# Required: allow read access to the content for analysis.
contents: read
# Optional: allow read access to pull request. Use with `only-new-issues` option.
pull-requests: read
# Optional: allow write access to checks to allow the action to annotate code in the PR.
checks: write

jobs:
lint:
name: run golangci-golint on the project
runs-on: ubuntu-latest
steps:
- uses: actions/setup-go@v3
- uses: actions/checkout@v4
- uses: actions/setup-go@v5
with:
go-version: '^1'

- run: go version

- uses: actions/checkout@v3

go-version: 'stable'
- name: golangci-golint
run: |
curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | sh -s v1.55.2
./bin/golangci-lint run -v ./...

uses: golangci/golangci-lint-action@v6
with:
version: v1.64.5
11 changes: 7 additions & 4 deletions .golangci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,14 +11,17 @@ linters:
- unused
- stylecheck

run:
skip-files:
issues:
exclude-dirs:
# These were code-generated, and cannot be changed without breaking RPC compatibility.
- lambda/messages/*.go
- lambda/messages

linters-settings:
staticcheck:
checks:
- all
- '-SA1029'
stylecheck:
go: "1.20"
checks:
- "all"
initialisms:
Expand Down
Loading