Skip to content

Commit 6c27cef

Browse files
committed
ci: drop go1.12 add go1.15
Switch to code generation happening against 1.14.9 Update README to reflect new minimum version of Go 1.13 Change-Id: If8d790fe6500a708a2ba7fd8737ffd380048a1be Reviewed-on: https://cue-review.googlesource.com/c/cue/+/7021 Reviewed-by: Paul Jolly <[email protected]>
1 parent 043c534 commit 6c27cef

File tree

4 files changed

+14
-18
lines changed

4 files changed

+14
-18
lines changed

.github/workflows/test.yml

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -16,9 +16,9 @@ jobs:
1616
fail-fast: false
1717
matrix:
1818
go-version:
19-
- 1.12.x
2019
- 1.13.x
21-
- 1.14.3
20+
- 1.14.9
21+
- 1.15.x
2222
os:
2323
- ubuntu-latest
2424
- macos-latest
@@ -38,15 +38,14 @@ jobs:
3838
key: ${{ runner.os }}-${{ matrix.go-version }}-go-${{ hashFiles('**/go.sum')
3939
}}
4040
restore-keys: ${{ runner.os }}-${{ matrix.go-version }}-go-
41-
- if: matrix.go-version == '1.14.3' && matrix.os != 'windows-latest'
41+
- if: matrix.go-version == '1.14.9' && matrix.os != 'windows-latest'
4242
name: Generate
4343
run: go generate ./...
4444
- name: Test
4545
run: go test ./...
4646
- name: Test with -race
4747
run: go test -race ./...
48-
- if: matrix.go-version == '1.14.3' || matrix.go-version == '1.13.x'
49-
name: gorelease check
48+
- name: gorelease check
5049
run: go run golang.org/x/exp/cmd/gorelease
5150
- name: Check that git is clean post generate and tests
5251
run: test -z "$(git status --porcelain)" || (git status; git diff; false)

.github/workflows/test_dispatch.yml

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -42,15 +42,14 @@ jobs:
4242
key: ${{ runner.os }}-${{ matrix.go-version }}-go-${{ hashFiles('**/go.sum')
4343
}}
4444
restore-keys: ${{ runner.os }}-${{ matrix.go-version }}-go-
45-
- if: matrix.go-version == '1.14.3' && matrix.os != 'windows-latest'
45+
- if: matrix.go-version == '1.14.9' && matrix.os != 'windows-latest'
4646
name: Generate
4747
run: go generate ./...
4848
- name: Test
4949
run: go test ./...
5050
- name: Test with -race
5151
run: go test -race ./...
52-
- if: matrix.go-version == '1.14.3' || matrix.go-version == '1.13.x'
53-
name: gorelease check
52+
- name: gorelease check
5453
run: go run golang.org/x/exp/cmd/gorelease
5554
- name: Check that git is clean post generate and tests
5655
run: test -z "$(git status --porcelain)" || (git status; git diff; false)
@@ -66,9 +65,9 @@ jobs:
6665
fail-fast: false
6766
matrix:
6867
go-version:
69-
- 1.12.x
7068
- 1.13.x
71-
- 1.14.3
69+
- 1.14.9
70+
- 1.15.x
7271
os:
7372
- ubuntu-latest
7473
- macos-latest

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
[![Github](https://github.com/cuelang/cue/workflows/Test/badge.svg)](https://github.com/cuelang/cue/actions)
1818
[![Go Report Card](https://goreportcard.com/badge/github.com/cuelang/cue)](https://goreportcard.com/report/github.com/cuelang/cue)
1919
[![GolangCI](https://golangci.com/badges/github.com/cuelang/cue.svg)](https://golangci.com/r/github.com/cuelang/cue)
20-
[![Go 1.12+](https://img.shields.io/badge/go-1.12-9cf.svg)](https://golang.org/dl/)
20+
[![Go 1.13+](https://img.shields.io/badge/go-1.13-9cf.svg)](https://golang.org/dl/)
2121
[![platforms](https://img.shields.io/badge/platforms-linux|windows|macos-inactive.svg)]()
2222

2323

internal/ci/workflows.cue

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -32,13 +32,14 @@ workflows: [
3232
#job: ((json.#Workflow & {}).jobs & {x: _}).x
3333
#step: ((#job & {steps: _}).steps & [_])[0]
3434

35-
#latestGo: "1.14.3"
35+
// We need at least go1.14 for code generation
36+
#codeGenGo: "1.14.9"
3637

3738
#testStrategy: {
3839
"fail-fast": false
3940
matrix: {
4041
// Use a stable version of 1.14.x for go generate
41-
"go-version": ["1.12.x", "1.13.x", #latestGo]
42+
"go-version": ["1.13.x", #codeGenGo, "1.15.x"]
4243
os: ["ubuntu-latest", "macos-latest", "windows-latest"]
4344
}
4445
}
@@ -70,9 +71,9 @@ workflows: [
7071
#goGenerate: #step & {
7172
name: "Generate"
7273
run: "go generate ./..."
73-
// The Go version corresponds to the precise 1.14.x version specified in
74+
// The Go version corresponds to the precise version specified in
7475
// the matrix. Skip windows for now until we work out why re-gen is flaky
75-
if: "matrix.go-version == '\(#latestGo)' && matrix.os != 'windows-latest'"
76+
if: "matrix.go-version == '\(#codeGenGo)' && matrix.os != 'windows-latest'"
7677
}
7778

7879
#goTest: #step & {
@@ -88,9 +89,6 @@ workflows: [
8889
#goReleaseCheck: #step & {
8990
name: "gorelease check"
9091
run: "go run golang.org/x/exp/cmd/gorelease"
91-
// Only run on 1.13.x and latest Go for now. Bug with Go 1.12.x means
92-
// this check fails
93-
if: "matrix.go-version == '\(#latestGo)' || matrix.go-version == '1.13.x'"
9492
}
9593

9694
#checkGitClean: #step & {

0 commit comments

Comments
 (0)