lego/.travis.yml
Ludovic Fernandez ad20bf90ff Migrate to golangci-lint (#644)
* refactor: linting.

- errcheck
- govet
- golint
- goconst
- spellcheck
- ...

* refactor: migrate from gometalinter to golangci-lint.
2018-09-24 19:07:20 +00:00

43 lines
1.2 KiB
YAML

language: go
go:
- 1.9.x
- 1.x
services:
- memcached
env:
- MEMCACHED_HOSTS=localhost:11211
before_install:
- '[ "${TRAVIS_PULL_REQUEST}" = "false" ] && openssl aes-256-cbc -K $encrypted_26c593b079d9_key -iv $encrypted_26c593b079d9_iv -in .gitcookies.enc -out .gitcookies -d || true'
# Download and install dep
- curl -sI https://github.com/golang/dep/releases/latest | grep -Fi Location | tr -d '\r' | sed "s/tag/download/g" | awk -F " " '{ print $2 "/dep-linux-amd64"}' | wget --output-document=$GOPATH/bin/dep -i -
- chmod +x $GOPATH/bin/dep
# Install linters and misspell
- curl -sfL https://install.goreleaser.com/github.com/golangci/golangci-lint.sh | bash -s -- -b $GOPATH/bin v1.10.2
- golangci-lint --version
install:
- dep status -v
deploy:
- provider: script
skip_cleanup: true
script: curl -sL https://git.io/goreleaser | bash
on:
tags: true
condition: $TRAVIS_GO_VERSION =~ ^1\.10\.[0-9]+$
- provider: releases
api_key: ${GITHUB_TOKEN}
file: dist/lego_*
skip_cleanup: true
overwrite: true
file_glob: true
on:
tags: true
condition: $TRAVIS_GO_VERSION =~ ^1\.10\.[0-9]+$