Skip to content

Commit decdb15

Browse files
authored
Merge pull request opencontainers#951 from sudo-bmitch/pr-go-1.17
Bump from Go 1.16 to 1.17
2 parents d2cc46d + 4c15674 commit decdb15

File tree

3 files changed

+18
-11
lines changed

3 files changed

+18
-11
lines changed

.github/workflows/docs-and-linting.yml

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -9,17 +9,16 @@ jobs:
99
runs-on: ubuntu-latest
1010
strategy:
1111
matrix:
12-
go: ['1.16', '1.17']
12+
go: ['1.17', '1.18', '1.19']
1313

1414
name: Documentation and Linting
1515
steps:
1616

17-
- uses: actions/checkout@v2
17+
- uses: actions/checkout@v3
1818
with:
1919
path: go/src/github.com/opencontainers/image-spec
2020

21-
# commit for v1 release
22-
- uses: actions/setup-go@0caeaed6fd66a828038c2da3c0f662a42862658f
21+
- uses: actions/setup-go@v3
2322
with:
2423
go-version: ${{ matrix.go }}
2524

@@ -40,7 +39,7 @@ jobs:
4039
make docs
4140
4241
- name: documentation artifacts
43-
uses: actions/upload-artifact@v2
42+
uses: actions/upload-artifact@v3
4443
with:
4544
name: oci-docs
4645
path: go/src/github.com/opencontainers/image-spec/output

Makefile

Lines changed: 11 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,8 @@ EPOCH_TEST_COMMIT ?= v0.2.0
33
DOCKER ?= $(shell command -v docker 2>/dev/null)
44
PANDOC ?= $(shell command -v pandoc 2>/dev/null)
55

6+
GOPATH:=$(shell go env GOPATH)
7+
68
OUTPUT_DIRNAME ?= output
79
DOC_FILENAME ?= oci-image-spec
810

@@ -87,7 +89,7 @@ check-license:
8789

8890
lint: .install.lint
8991
@echo "checking lint"
90-
@GO111MODULE=on golangci-lint run
92+
@GO111MODULE=on $(GOPATH)/bin/golangci-lint run
9193

9294
test: schema/fs.go
9395
go test -race -cover $(shell go list ./... | grep -v /vendor/)
@@ -100,18 +102,22 @@ img/%.png: img/%.dot
100102
.gitvalidation:
101103
@which git-validation > /dev/null 2>/dev/null || (echo "ERROR: git-validation not found. Consider 'make install.tools' target" && false)
102104
ifdef GITHUB_SHA
103-
git-validation -q -run DCO,short-subject,dangling-whitespace -range $(GITHUB_SHA)..HEAD
105+
$(GOPATH)/bin/git-validation -q -run DCO,short-subject,dangling-whitespace -range $(GITHUB_SHA)..HEAD
104106
else
105-
git-validation -v -run DCO,short-subject,dangling-whitespace -range $(EPOCH_TEST_COMMIT)..HEAD
107+
$(GOPATH)/bin/git-validation -v -run DCO,short-subject,dangling-whitespace -range $(EPOCH_TEST_COMMIT)..HEAD
106108
endif
107109

108110
install.tools: $(TOOLS:%=.install.%)
109111

110112
.install.lint:
111-
go get github.com/golangci/golangci-lint/cmd/[email protected]
113+
case "$$(go env GOVERSION)" in \
114+
go1.17.*) go install github.com/golangci/golangci-lint/cmd/[email protected];; \
115+
go1.18.*) go install github.com/golangci/golangci-lint/cmd/[email protected];; \
116+
*) go install github.com/golangci/golangci-lint/cmd/golangci-lint@latest;; \
117+
esac
112118

113119
.install.gitvalidation:
114-
go get -u github.com/vbatts/git-validation
120+
go install github.com/vbatts/git-validation@latest
115121

116122
clean:
117123
rm -rf *~ $(OUTPUT_DIRNAME) header.html

go.mod

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
module github.com/opencontainers/image-spec
22

3-
go 1.16
3+
go 1.17
44

55
require (
66
github.com/davecgh/go-spew v1.1.1 // indirect
@@ -12,3 +12,5 @@ require (
1212
github.com/xeipuuv/gojsonschema v1.2.0
1313
gopkg.in/yaml.v3 v3.0.0-20210107192922-496545a6307b // indirect
1414
)
15+
16+
require github.com/xeipuuv/gojsonpointer v0.0.0-20180127040702-4e3ac2762d5f // indirect

0 commit comments

Comments
 (0)