Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 0ead339

Browse files
committed
Bump golang ci lint to work with go 1.24
1 parent 4396e40 commit 0ead339

File tree

3 files changed

+4
-4
lines changed

3 files changed

+4
-4
lines changed

.github/workflows/lint.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ jobs:
3232
go mod verify
3333
go mod download
3434
35-
LINT_VERSION=1.59.1
35+
LINT_VERSION=1.63.4
3636
curl -fsSL https://github.com/golangci/golangci-lint/releases/download/v${LINT_VERSION}/golangci-lint-${LINT_VERSION}-linux-amd64.tar.gz | \
3737
tar xz --strip-components 1 --wildcards \*/golangci-lint
3838
mkdir -p bin && mv golangci-lint bin/
@@ -53,6 +53,6 @@ jobs:
5353
assert-nothing-changed go fmt ./...
5454
assert-nothing-changed go mod tidy
5555
56-
bin/golangci-lint run --out-format=github-actions --timeout=3m || STATUS=$?
56+
bin/golangci-lint run --out-format=colored-line-number --timeout=3m || STATUS=$?
5757
5858
exit $STATUS

pkg/cmd/ruleset/shared/shared.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,7 @@ func ParseRulesForDisplay(rules []RulesetRule) string {
7878
for _, rule := range rules {
7979
display.WriteString(fmt.Sprintf("- %s", rule.Type))
8080

81-
if rule.Parameters != nil && len(rule.Parameters) > 0 {
81+
if len(rule.Parameters) > 0 {
8282
display.WriteString(": ")
8383

8484
// sort these keys too for consistency

pkg/cmdutil/json_flags.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -254,7 +254,7 @@ func (e *jsonExporter) exportData(v reflect.Value) interface{} {
254254
}
255255
return m.Interface()
256256
case reflect.Struct:
257-
if v.CanAddr() && reflect.PtrTo(v.Type()).Implements(exportableType) {
257+
if v.CanAddr() && reflect.PointerTo(v.Type()).Implements(exportableType) {
258258
ve := v.Addr().Interface().(exportable)
259259
return ve.ExportData(e.fields)
260260
} else if v.Type().Implements(exportableType) {

0 commit comments

Comments
 (0)