circleci right go version

This commit is contained in:
Andrew Jackson (Ajax) 2023-09-21 17:25:58 -05:00
parent 20bd597f34
commit cdde64b6f2
3 changed files with 17 additions and 5 deletions

View File

@ -164,7 +164,7 @@ jobs:
default: unit
description: Test suite name to report to CircleCI.
docker:
- image: cimg/go:1.19.7
- image: cimg/go:1.20.7
environment:
LOTUS_HARMONYDB_HOSTS: yugabyte
- image: yugabytedb/yugabyte:latest
@ -218,7 +218,7 @@ jobs:
test with. If empty (the default) the commit defined by the git
submodule is used.
docker:
- image: cimg/go:1.19.7
- image: cimg/go:1.20.7
resource_class: << parameters.resource_class >>
steps:
- install-ubuntu-deps
@ -412,7 +412,7 @@ jobs:
description: |
Arguments to pass to golangci-lint
docker:
- image: cimg/go:1.19.7
- image: cimg/go:1.20.7
resource_class: medium+
steps:
- install-ubuntu-deps

View File

@ -10,13 +10,25 @@ import (
"text/template"
)
const GoVersion = "1.19.7"
var GoVersion = "" // from init below. Ex: 1.19.7
//go:generate go run ./gen.go ..
//go:embed template.yml
var templateFile embed.FS
func init() {
b, err := os.ReadFile("../go.mod")
if err != nil {
panic("cannot find go.mod in parent folder")
}
for _, line := range strings.Split(string(b), "\n") {
if strings.HasPrefix(line, "go ") {
GoVersion = line[3:]
}
}
}
type (
dirs = []string
suite = string

2
go.mod
View File

@ -1,6 +1,6 @@
module github.com/filecoin-project/lotus
go 1.19
go 1.20.7
retract v1.14.0 // Accidentally force-pushed tag, use v1.14.1+ instead.