Skip to content

Commit 4c339e1

Browse files
authored
chore(ci): upgrade go to v1.23 and linter
1 parent dec1ed8 commit 4c339e1

File tree

6 files changed

+7
-25
lines changed

6 files changed

+7
-25
lines changed

.github/workflows/ci.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ jobs:
1313
runs-on: ubuntu-latest
1414
env:
1515
GO_VERSION: stable
16-
GOLANGCI_LINT_VERSION: v1.58.0
16+
GOLANGCI_LINT_VERSION: v1.63.4
1717
CGO_ENABLED: 0
1818

1919
steps:

.golangci.yml

Lines changed: 1 addition & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -52,30 +52,18 @@ linters-settings:
5252
linters:
5353
enable-all: true
5454
disable:
55-
- deadcode # deprecated
56-
- exhaustivestruct # deprecated
57-
- golint # deprecated
58-
- ifshort # deprecated
59-
- interfacer # deprecated
60-
- maligned # deprecated
61-
- nosnakecase # deprecated
62-
- scopelint # deprecated
63-
- scopelint # deprecated
64-
- structcheck # deprecated
65-
- varcheck # deprecated
66-
- execinquery # not relevant (SQL)
6755
- rowserrcheck # not relevant (SQL)
6856
- sqlclosecheck # not relevant (SQL)
6957
- cyclop # duplicate of gocyclo
7058
- dupl
7159
- exhaustive
7260
- exhaustruct
61+
- exportloopref
7362
- forbidigo
7463
- gochecknoglobals
7564
- gochecknoinits
7665
- err113
7766
- mnd
78-
- gomnd
7967
- gosec
8068
- lll
8169
- nilnil

app.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -159,7 +159,7 @@ func echoHandler(w http.ResponseWriter, r *http.Request) {
159159

160160
func printBinary(s []byte) {
161161
fmt.Printf("Received b:")
162-
for n := 0; n < len(s); n++ {
162+
for n := range s {
163163
fmt.Printf("%d,", s[n])
164164
}
165165
fmt.Printf("\n")

content_test.go

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,6 @@ func Test_contentReader_Read(t *testing.T) {
1919
}
2020

2121
for _, test := range tests {
22-
test := test
2322
t.Run(test.name, func(t *testing.T) {
2423
t.Parallel()
2524

@@ -56,7 +55,6 @@ func Test_contentReader_ReadSeek(t *testing.T) {
5655
}
5756

5857
for _, test := range tests {
59-
test := test
6058
t.Run(test.name, func(t *testing.T) {
6159
t.Parallel()
6260

go.mod

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,5 @@
11
module github.com/traefik/whoami
22

3-
go 1.21
3+
go 1.23
44

5-
require github.com/gorilla/websocket v1.5.1
6-
7-
require golang.org/x/net v0.25.0 // indirect
5+
require github.com/gorilla/websocket v1.5.3

go.sum

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,2 @@
1-
github.com/gorilla/websocket v1.5.1 h1:gmztn0JnHVt9JZquRuzLw3g4wouNVzKL15iLr/zn/QY=
2-
github.com/gorilla/websocket v1.5.1/go.mod h1:x3kM2JMyaluk02fnUJpQuwD2dCS5NDG2ZHL0uE0tcaY=
3-
golang.org/x/net v0.25.0 h1:d/OCCoBEUq33pjydKrGQhw7IlUPI2Oylr+8qLx49kac=
4-
golang.org/x/net v0.25.0/go.mod h1:JkAGAh7GEvH74S6FOH42FLoXpXbE/aqXSrIQjXgsiwM=
1+
github.com/gorilla/websocket v1.5.3 h1:saDtZ6Pbx/0u+bgYQ3q96pZgCzfhKXGPqt7kZ72aNNg=
2+
github.com/gorilla/websocket v1.5.3/go.mod h1:YR8l580nyteQvAITg2hZ9XVh4b55+EU/adAjf1fMHhE=

0 commit comments

Comments
 (0)