Skip to content

Commit 694b951

Browse files
authoredFeb 19, 2025··
Update lint.yml (#586)
* Update lint.yml * Update .golangci.yml * Update .golangci.yml * Update lint.yml * Update .golangci.yml
1 parent 8e674da commit 694b951

File tree

2 files changed

+21
-15
lines changed

2 files changed

+21
-15
lines changed
 

‎.github/workflows/lint.yml

+14-11
Original file line numberDiff line numberDiff line change
@@ -3,21 +3,24 @@ on:
33
push:
44
pull_request:
55

6+
permissions:
7+
# Required: allow read access to the content for analysis.
8+
contents: read
9+
# Optional: allow read access to pull request. Use with `only-new-issues` option.
10+
pull-requests: read
11+
# Optional: allow write access to checks to allow the action to annotate code in the PR.
12+
checks: write
13+
614
jobs:
715
lint:
816
name: run golangci-golint on the project
917
runs-on: ubuntu-latest
1018
steps:
11-
- uses: actions/setup-go@v3
19+
- uses: actions/checkout@v4
20+
- uses: actions/setup-go@v5
1221
with:
13-
go-version: '^1'
14-
15-
- run: go version
16-
17-
- uses: actions/checkout@v3
18-
22+
go-version: 'stable'
1923
- name: golangci-golint
20-
run: |
21-
curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | sh -s v1.55.2
22-
./bin/golangci-lint run -v ./...
23-
24+
uses: golangci/golangci-lint-action@v6
25+
with:
26+
version: v1.64.5

‎.golangci.yml

+7-4
Original file line numberDiff line numberDiff line change
@@ -11,14 +11,17 @@ linters:
1111
- unused
1212
- stylecheck
1313

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

1919
linters-settings:
20+
staticcheck:
21+
checks:
22+
- all
23+
- '-SA1029'
2024
stylecheck:
21-
go: "1.20"
2225
checks:
2326
- "all"
2427
initialisms:

0 commit comments

Comments
 (0)
Please sign in to comment.