Skip to content

Commit 14345b0

Browse files
committed
chore: update example
1 parent 4ae21cd commit 14345b0

File tree

4 files changed

+18
-25
lines changed

4 files changed

+18
-25
lines changed

.github/workflows/basic.yml

+2-3
Original file line numberDiff line numberDiff line change
@@ -40,12 +40,11 @@ jobs:
4040
CGO_ENABLED: 1
4141

4242
- name: golangci-lint
43-
uses: golangci/golangci-lint-action@v6
43+
uses: golangci/golangci-lint-action@v7
4444
with:
45-
version: v1.59.1
45+
version: v2.1.1
4646
# The installation mode `goinstall` always uses `CGO_ENABLED=1`.
4747
install-mode: goinstall
48-
args: --timeout=10m
4948

5049
- name: Test
5150
run: go test -v -cover ./...

.golangci.yml

+13-18
Original file line numberDiff line numberDiff line change
@@ -1,25 +1,20 @@
1-
run:
2-
timeout: 10m
3-
skip-files: []
4-
5-
linters-settings:
6-
custom:
7-
example:
8-
# Path to the `.so` file of the plugin
9-
path: .plugins/example.so
10-
# Only used for documentation purposes.
11-
description: The description of the linter. Shows up when running `golangci-lint linters`.
12-
# Only used for documentation purposes.
13-
original-url: github.com/golangci/example-linter
1+
version: "2"
142

153
linters:
16-
disable-all: true
4+
default: none
175
enable:
186
- example
19-
- typecheck
7+
8+
settings:
9+
custom:
10+
example:
11+
# Path to the `.so` file of the plugin
12+
path: .plugins/example.so
13+
# Only used for documentation purposes.
14+
description: The description of the linter. Shows up when running `golangci-lint linters`.
15+
# Only used for documentation purposes.
16+
original-url: github.com/golangci/example-linter
2017

2118
issues:
22-
exclude-use-default: false
23-
max-per-linter: 0
19+
max-issues-per-linter: 0
2420
max-same-issues: 0
25-

go.mod

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
module github.com/golangci/golangci-lint-action-plugin-example
22

3-
go 1.20
3+
go 1.23.0

readme.md

+2-3
Original file line numberDiff line numberDiff line change
@@ -19,12 +19,11 @@ This repository is an example to explain how to use [custom linters](https://gol
1919
2020
```yml
2121
- name: golangci-lint
22-
uses: golangci/golangci-lint-action@v3
22+
uses: golangci/golangci-lint-action@v7
2323
with:
24-
version: v1.53.2
24+
version: v2.1.1
2525
# The installation mode `goinstall` always uses `CGO_ENABLED=1`.
2626
install-mode: goinstall
27-
args: --timeout=5m
2827
```
2928
3029
## Full Example

0 commit comments

Comments
 (0)