Skip to content

Commit 14bfe7b

Browse files
Bump golangci/golangci-lint-action from 6 to 7 (#460)
* Bump golangci/golangci-lint-action from 6 to 7 Bumps [golangci/golangci-lint-action](https://github.com/golangci/golangci-lint-action) from 6 to 7. - [Release notes](https://github.com/golangci/golangci-lint-action/releases) - [Commits](golangci/golangci-lint-action@v6...v7) --- updated-dependencies: - dependency-name: golangci/golangci-lint-action dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <support@github.com> * Update golangci-lint configuration and fix linting issues --------- Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Andreas Fritzler <andreas.fritzler@sap.com>
1 parent d6e354e commit 14bfe7b

File tree

4 files changed

+38
-24
lines changed

4 files changed

+38
-24
lines changed

.github/workflows/lint.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,6 @@ jobs:
1919
go-version-file: 'go.mod'
2020

2121
- name: Run golangci-lint
22-
uses: golangci/golangci-lint-action@v6
22+
uses: golangci/golangci-lint-action@v7
2323
with:
24-
version: v1.62
24+
version: v2.0

.golangci.yaml

Lines changed: 31 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,35 @@
1-
run:
2-
timeout: 5m
3-
1+
version: "2"
42
linters:
53
enable:
6-
- revive
7-
- ineffassign
8-
- misspell
9-
- goimports
104
- importas
11-
5+
- misspell
6+
- revive
7+
settings:
8+
revive:
9+
severity: error
10+
rules:
11+
- name: exported
12+
- name: if-return
13+
disabled: true
14+
exclusions:
15+
generated: lax
16+
presets:
17+
- comments
18+
- common-false-positives
19+
- legacy
20+
- std-error-handling
21+
paths:
22+
- third_party$
23+
- builtin$
24+
- examples$
1225
severity:
13-
default-severity: error
14-
15-
linters-settings:
16-
revive:
17-
severity: error
18-
rules:
19-
- name: exported
20-
- name: if-return
21-
disabled: true
26+
default: error
27+
formatters:
28+
enable:
29+
- goimports
30+
exclusions:
31+
generated: lax
32+
paths:
33+
- third_party$
34+
- builtin$
35+
- examples$

Makefile

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -118,8 +118,8 @@ GOLANGCI_LINT ?= $(LOCALBIN)/golangci-lint
118118
KUSTOMIZE_VERSION ?= v5.5.0
119119
ADDLICENSE_VERSION ?= v1.1.1
120120
GEN_CRD_API_REFERENCE_DOCS_VERSION ?= v0.3.0
121-
GOIMPORTS_VERSION ?= v0.26.0
122-
GOLANGCI_LINT_VERSION ?= v1.62.2
121+
GOIMPORTS_VERSION ?= v0.31.0
122+
GOLANGCI_LINT_VERSION ?= v2.0
123123

124124
KUSTOMIZE_INSTALL_SCRIPT ?= "https://raw.githubusercontent.com/kubernetes-sigs/kustomize/master/hack/install_kustomize.sh"
125125
.PHONY: kustomize
@@ -150,4 +150,4 @@ $(GEN_CRD_API_REFERENCE_DOCS): $(LOCALBIN)
150150
.PHONY: golangci-lint
151151
golangci-lint: $(GOLANGCI_LINT) ## Download golangci-lint locally if necessary.
152152
$(GOLANGCI_LINT): $(LOCALBIN)
153-
test -s $(LOCALBIN)/golangci-lint || GOBIN=$(LOCALBIN) go install github.com/golangci/golangci-lint/cmd/golangci-lint@$(GOLANGCI_LINT_VERSION)
153+
test -s $(LOCALBIN)/golangci-lint || GOBIN=$(LOCALBIN) go install github.com/golangci/golangci-lint/v2/cmd/golangci-lint@$(GOLANGCI_LINT_VERSION)

pkg/ironcore/suite_test.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -210,11 +210,11 @@ func newMachine(namespace *corev1.Namespace, prefix string, setMachineIndex int,
210210
}
211211
}
212212

213-
machine.Spec.NodeTemplateSpec.ObjectMeta.Annotations = make(map[string]string)
213+
machine.Spec.NodeTemplateSpec.Annotations = make(map[string]string)
214214

215215
//appending to already existing annotations
216216
for k, v := range annotations {
217-
machine.Spec.NodeTemplateSpec.ObjectMeta.Annotations[k] = v
217+
machine.Spec.NodeTemplateSpec.Annotations[k] = v
218218
}
219219
return machine
220220
}

0 commit comments

Comments
 (0)