From ee84146d19962dbc059040f0d83f899122387d30 Mon Sep 17 00:00:00 2001 From: Ivan Kozlovic Date: Thu, 30 Mar 2023 18:08:09 -0600 Subject: [PATCH] Change travis to exclude staticcheck on Go 1.18 Signed-off-by: Ivan Kozlovic --- .travis.yml | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/.travis.yml b/.travis.yml index 6f62ab8a..ea5c699d 100644 --- a/.travis.yml +++ b/.travis.yml @@ -16,8 +16,10 @@ env: go_import_path: github.com/nats-io/nats-streaming-server install: - if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then - go install honnef.co/go/tools/cmd/staticcheck@latest; - go install github.com/client9/misspell/cmd/misspell@latest; + if [[ "$TRAVIS_GO_VERSION" =~ 1.19 ]]; then + go install honnef.co/go/tools/cmd/staticcheck@latest; + go install github.com/client9/misspell/cmd/misspell@latest; + fi; fi services: - mysql @@ -27,8 +29,10 @@ before_script: go install; $(exit $(go fmt $GO_LIST | wc -l)); go vet $GO_LIST; - find . -type f -name "*.go" | grep -v "/spb/" | xargs misspell -error -locale US; - staticcheck $GO_LIST; + if [[ "$TRAVIS_GO_VERSION" =~ 1.19 ]]; then + find . -type f -name "*.go" | grep -v "/spb/" | xargs misspell -error -locale US; + staticcheck $GO_LIST; + fi; fi script: - set -e