Skip to content

Commit 692abcb

Browse files
committed
.travis: Bump minimum Go version to 1.9
Go 1.10 was released on 2018-02-16 [1] and Go only supports the last two major releases [2] (so currently 1.9 and 1.10). Besides ensuring that we are compatible with the currently-maintained releases, this will avoid our current test failure now that golint has dropped support for Go 1.6 [3]: $ make install.tools go get -u github.com/golang/lint/golint # golang.org/x/tools/go/internal/gcimporter ../../../golang.org/x/tools/go/internal/gcimporter/iimport.go:77: undefined: io.SeekCurrent ../../../golang.org/x/tools/go/internal/gcimporter/iimport.go:80: undefined: io.SeekCurrent ../../../golang.org/x/tools/go/internal/gcimporter/iimport.go:156: undefined: io.SeekCurrent ../../../golang.org/x/tools/go/internal/gcimporter/iimport.go:187: r.declReader.Reset undefined (type bytes.Reader has no field or method Reset) ../../../golang.org/x/tools/go/internal/gcimporter/iimport.go:226: r.declReader.Reset undefined (type bytes.Reader has no field or method Reset) make: *** [.install.golint] Error 2 Quoting the versions in the Travis YAML is recommended to avoid them being interpreted as floating point numbers [4]. [1]: https://golang.org/doc/devel/release.html#go1.10 [2]: https://golang.org/doc/devel/release.html#policy [3]: https://travis-ci.org/opencontainers/runtime-spec/jobs/376692151#L469 [4]: https://docs.travis-ci.com/user/languages/go/#Specifying-a-Go-version-to-use Signed-off-by: W. Trevor King <[email protected]>
1 parent a1998ec commit 692abcb

File tree

2 files changed

+5
-6
lines changed

2 files changed

+5
-6
lines changed

.travis.yml

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,7 @@
11
language: go
22
go:
3-
- 1.7
4-
- 1.6.3
5-
- 1.5.4
3+
- "1.10.x"
4+
- "1.9.x"
65

76
sudo: required
87

Makefile

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ test: .govet .golint .gitvalidation
6262

6363
# `go get github.com/golang/lint/golint`
6464
.golint:
65-
ifeq ($(call ALLOWED_GO_VERSION,1.6,$(HOST_GOLANG_VERSION)),true)
65+
ifeq ($(call ALLOWED_GO_VERSION,1.7,$(HOST_GOLANG_VERSION)),true)
6666
@which golint > /dev/null 2>/dev/null || (echo "ERROR: golint not found. Consider 'make install.tools' target" && false)
6767
golint ./...
6868
endif
@@ -79,9 +79,9 @@ endif
7979

8080
install.tools: .install.golint .install.gitvalidation
8181

82-
# golint does not even build for <go1.6
82+
# golint does not even build for <go1.7
8383
.install.golint:
84-
ifeq ($(call ALLOWED_GO_VERSION,1.6,$(HOST_GOLANG_VERSION)),true)
84+
ifeq ($(call ALLOWED_GO_VERSION,1.7,$(HOST_GOLANG_VERSION)),true)
8585
go get -u github.com/golang/lint/golint
8686
endif
8787

0 commit comments

Comments
 (0)