From acd3fa49ea468a8f3593f6f590d12cc301499fdf Mon Sep 17 00:00:00 2001 From: Vincent Batts Date: Thu, 8 Nov 2018 11:50:04 -0500 Subject: [PATCH] travis, golint, and versions of golang! Signed-off-by: Vincent Batts --- .travis.yml | 9 +++++---- Makefile | 8 ++++++-- 2 files changed, 11 insertions(+), 6 deletions(-) diff --git a/.travis.yml b/.travis.yml index 39020cc..2f76686 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,9 +1,10 @@ language: go go: - - 1.x - - 1.10.x - - 1.9.x - - 1.8.x + - "1.x" + - "1.11.x" + - "1.10.x" + - "1.9.x" + - "1.8.x" sudo: false diff --git a/Makefile b/Makefile index a4ec422..bd98334 100644 --- a/Makefile +++ b/Makefile @@ -32,7 +32,11 @@ lint: .lint CLEAN_FILES += .lint .lint: $(SOURCE_FILES) - set -e ; for dir in $$(glide novendor) ; do golint -set_exit_status $$dir ; done && touch $@ + if [[ "$(go version |awk '{ print $3 }')" =~ ^go1\.11\. ]] ; then \ + set -e ; for dir in $$(glide novendor) ; do golint -set_exit_status $$dir ; done && touch $@ \ + else \ + touch $@ ; \ + fi .PHONY: vet vet: .vet .vet.tags @@ -64,7 +68,7 @@ $(BUILD): $(SOURCE_FILES) install.tools: go get -u -v github.com/Masterminds/glide - go get -u -v golang.org/x/lint/golint + if [[ "$(go version |awk '{ print $3 }')" =~ ^go1\.11\. ]] ; then go get -u golang.org/x/lint/golint ; fi ./bin: mkdir -p $@