Skip to content

Commit

Permalink
Update to Go 1.22 (#33)
Browse files Browse the repository at this point in the history
  • Loading branch information
yunussandikci committed Feb 19, 2024
1 parent 5438f77 commit 167529f
Show file tree
Hide file tree
Showing 12 changed files with 192 additions and 18 deletions.
6 changes: 1 addition & 5 deletions .github/workflows/lint.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,7 @@ permissions:
contents: read

env:
GO_VERSION: "1.21"
GOLANGCI_LINT_VERSION: "v1.55.2"
GO_VERSION: "1.22"

jobs:
lint:
Expand All @@ -23,6 +22,3 @@ jobs:
run: go mod download
- name: golangci-lint
uses: golangci/golangci-lint-action@v3
with:
version: ${{ env.GOLANGCI_LINT_VERSION }}
args: --timeout=10m
2 changes: 1 addition & 1 deletion .github/workflows/release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ on:
env:
IMAGE: "nccloud/mayfly"
REGISTRY: "ghcr.io"
GO_VERSION: "1.21"
GO_VERSION: "1.22"
TAG: ${{ github.event.release.tag_name }}

jobs:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ permissions:
contents: write

env:
GO_VERSION: "1.21"
GO_VERSION: "1.22"
GOPRIVATE: "github:com/NCCloud/*"

jobs:
Expand Down
4 changes: 3 additions & 1 deletion .golangci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13,11 +13,13 @@ linters:
- tagalign # Buggy
- lll
- funlen
- perfsprint
linters-settings:
cyclop:
max-complexity: 12
run:
go: '1.21'
go: '1.22'
timeout: 10m
tests: false
skip-dirs:
- cmd/benchmark
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM golang:1.21 as builder
FROM golang:1.22 as builder

WORKDIR /workspace
COPY go.mod go.mod
Expand Down
6 changes: 3 additions & 3 deletions devops.sh
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
#!/usr/bin/env bash

export CONTROLLER_GEN_VERSION="v0.14.0"
export GOLANGCI_LINT_VERSION="v1.55.2"
export MOCKERY_GEN_VERSION="v2.36.0"
export GOFUMPT_VERSION="v0.5.0"
export GOLANGCI_LINT_VERSION="v1.56.2"
export MOCKERY_GEN_VERSION="v2.42.0"
export GOFUMPT_VERSION="v0.6.0"
export TESTENV_VERSION="1.25.x!"

prerequisites() {
Expand Down
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
module github.com/NCCloud/mayfly

go 1.21
go 1.22

require (
github.com/araddon/dateparse v0.0.0-20210429162001-6b43995a97de
Expand Down
10 changes: 9 additions & 1 deletion mocks/github.com/NCCloud/mayfly/pkg/common/mock_Scheduler.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

34 changes: 33 additions & 1 deletion mocks/sigs.k8s.io/controller-runtime/pkg/cache/mock_Cache.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

54 changes: 53 additions & 1 deletion mocks/sigs.k8s.io/controller-runtime/pkg/client/mock_Client.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit 167529f

Please sign in to comment.