Skip to content

Commit

Permalink
🌱 Bump to go1.23 (#195)
Browse files Browse the repository at this point in the history
* Bump to go1.23

Signed-off-by: Per Goncalves da Silva <pegoncal@redhat.com>

* Update bingo deps

Signed-off-by: Per Goncalves da Silva <pegoncal@redhat.com>

* Address lint errors

Signed-off-by: Per Goncalves da Silva <pegoncal@redhat.com>

* Fix up golangci-lint version in GHA

Signed-off-by: Per Goncalves da Silva <pegoncal@redhat.com>

* address lint issues

Signed-off-by: Per Goncalves da Silva <pegoncal@redhat.com>

---------

Signed-off-by: Per Goncalves da Silva <pegoncal@redhat.com>
Co-authored-by: Per Goncalves da Silva <pegoncal@redhat.com>
  • Loading branch information
perdasilva and Per Goncalves da Silva authored Jan 13, 2025
1 parent b42b4a9 commit be2540b
Show file tree
Hide file tree
Showing 8 changed files with 185 additions and 13 deletions.
6 changes: 3 additions & 3 deletions .bingo/Variables.mk
Original file line number Diff line number Diff line change
Expand Up @@ -23,9 +23,9 @@ $(BINGO): $(BINGO_DIR)/bingo.mod
@echo "(re)installing $(GOBIN)/bingo-v0.9.0"
@cd $(BINGO_DIR) && GOWORK=off $(GO) build -mod=mod -modfile=bingo.mod -o=$(GOBIN)/bingo-v0.9.0 "github.com/bwplotka/bingo"

GOLANGCI_LINT := $(GOBIN)/golangci-lint-v1.60.3
GOLANGCI_LINT := $(GOBIN)/golangci-lint-v1.63.4
$(GOLANGCI_LINT): $(BINGO_DIR)/golangci-lint.mod
@# Install binary/ries using Go 1.14+ build command. This is using bwplotka/bingo-controlled, separate go module with pinned dependencies.
@echo "(re)installing $(GOBIN)/golangci-lint-v1.60.3"
@cd $(BINGO_DIR) && GOWORK=off $(GO) build -mod=mod -modfile=golangci-lint.mod -o=$(GOBIN)/golangci-lint-v1.60.3 "github.com/golangci/golangci-lint/cmd/golangci-lint"
@echo "(re)installing $(GOBIN)/golangci-lint-v1.63.4"
@cd $(BINGO_DIR) && GOWORK=off $(GO) build -mod=mod -modfile=golangci-lint.mod -o=$(GOBIN)/golangci-lint-v1.63.4 "github.com/golangci/golangci-lint/cmd/golangci-lint"

2 changes: 1 addition & 1 deletion .bingo/golangci-lint.mod
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,4 @@ go 1.22.1

toolchain go1.22.3

require github.com/golangci/golangci-lint v1.60.3 // cmd/golangci-lint
require github.com/golangci/golangci-lint v1.63.4 // cmd/golangci-lint
170 changes: 170 additions & 0 deletions .bingo/golangci-lint.sum

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion .bingo/variables.env
Original file line number Diff line number Diff line change
Expand Up @@ -10,5 +10,5 @@ fi

BINGO="${GOBIN}/bingo-v0.9.0"

GOLANGCI_LINT="${GOBIN}/golangci-lint-v1.60.3"
GOLANGCI_LINT="${GOBIN}/golangci-lint-v1.63.4"

2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ jobs:
go-version-file: "go.mod"
- uses: golangci/golangci-lint-action@v6
with:
version: v1.57
version: v1.63.4
args: --timeout 5m

go-apidiff:
Expand Down
4 changes: 3 additions & 1 deletion go.mod
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
module github.com/operator-framework/operator-lib

go 1.22.0
go 1.23.0

toolchain go1.23.4

require (
github.com/go-logr/logr v1.4.2
Expand Down
6 changes: 3 additions & 3 deletions internal/annotation/suite_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -34,10 +34,10 @@ func makeCreateEventFor(obj client.Object) event.CreateEvent {
return e
}

func makeUpdateEventFor(old, new client.Object) event.UpdateEvent {
func makeUpdateEventFor(oldObj, newObj client.Object) event.UpdateEvent {
var e event.UpdateEvent
e.ObjectOld = old
e.ObjectNew = new
e.ObjectOld = oldObj
e.ObjectNew = newObj
return e
}

Expand Down
6 changes: 3 additions & 3 deletions predicate/predicate_suite_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -34,10 +34,10 @@ func makeCreateEventFor(obj client.Object) event.CreateEvent {
return e
}

func makeUpdateEventFor(old, new client.Object) event.UpdateEvent {
func makeUpdateEventFor(oldObj, newObj client.Object) event.UpdateEvent {
var e event.UpdateEvent
e.ObjectOld = old
e.ObjectNew = new
e.ObjectOld = oldObj
e.ObjectNew = newObj
return e
}

Expand Down

0 comments on commit be2540b

Please sign in to comment.