Skip to content

Commit

Permalink
chore: upgrade go 1.23
Browse files Browse the repository at this point in the history
  • Loading branch information
thisislawatts authored and sandor-trombitas committed Oct 17, 2024
1 parent 1c824e1 commit 2888357
Show file tree
Hide file tree
Showing 6 changed files with 15 additions and 10 deletions.
3 changes: 2 additions & 1 deletion .circleci/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
FROM --platform=$TARGETPLATFORM golang:1.22-bullseye
# When upgrading golang, make sure to update the docker executors that use snyklabs/cli-build in .circleci/config.yml
FROM --platform=$TARGETPLATFORM golang:1.23-bullseye

# install "normal" stuff

Expand Down
10 changes: 5 additions & 5 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ parameters:
go_version:
type: string
# https://go.dev/doc/devel/release
default: '1.22.6'
default: '1.23.2'
aws_version:
type: string
# https://github.com/aws/aws-cli/blob/v2/CHANGELOG.rst
Expand Down Expand Up @@ -47,22 +47,22 @@ executors:
resource_class: small
docker-amd64:
docker:
- image: snyklabs/cli-build:20240814-161347
- image: snyklabs/cli-build:20241015-082358
working_directory: /mnt/ramdisk/snyk
resource_class: large
docker-amd64-xl:
docker:
- image: snyklabs/cli-build:20240814-161347
- image: snyklabs/cli-build:20241015-082358
working_directory: /mnt/ramdisk/snyk
resource_class: xlarge
docker-arm64:
docker:
- image: snyklabs/cli-build-arm64:20240814-161347
- image: snyklabs/cli-build-arm64:20241015-082358
working_directory: /mnt/ramdisk/snyk
resource_class: arm.large
docker-arm64-xl:
docker:
- image: snyklabs/cli-build-arm64:20240814-161347
- image: snyklabs/cli-build-arm64:20241015-082358
working_directory: /mnt/ramdisk/snyk
resource_class: arm.xlarge
linux-ubuntu-mantic-amd64:
Expand Down
4 changes: 4 additions & 0 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -356,6 +356,10 @@ If you have made changes to the `go-application-framework`, you can run `python3

You can then raise a pr with the relevant changes.

## Upgrading go-lang versions

When upgrading golang, you will need to update the Dockerfile under .circleci, run the _Create Build Image_ job on github, and update the docker executor that use the `snyklabs/cli-build` image in the .circleci/config.yml file, to use the new image.

---

Questions? Ask Hammerhead 🔨
2 changes: 1 addition & 1 deletion cliv2/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ export LS_PROTOCOL_VERSION=

# Build tools
GO_BIN := $(shell pwd)/.bin
OVERRIDE_GOCI_LINT_V := v1.59.1
OVERRIDE_GOCI_LINT_V := v1.61.0
SHELL := env PATH=$(GO_BIN):$(PATH) $(SHELL)

# Make directories per convention
Expand Down
2 changes: 1 addition & 1 deletion cliv2/cmd/cliv2/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -307,7 +307,7 @@ func getGlobalFLags() *pflag.FlagSet {
}

func emptyCommandFunction(_ *cobra.Command, _ []string) error {
return fmt.Errorf(unknownCommandMessage)
return fmt.Errorf("%s", unknownCommandMessage)
}

func createCommandsForWorkflows(rootCommand *cobra.Command, engine workflow.Engine) {
Expand Down
4 changes: 2 additions & 2 deletions cliv2/go.mod
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
module github.com/snyk/cli/cliv2

go 1.22
go 1.23

toolchain go1.22.6
toolchain go1.23.2

require (
github.com/elazarl/goproxy v0.0.0-20231031074852-3ec07828be7a
Expand Down

0 comments on commit 2888357

Please sign in to comment.