-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.travis.yml
58 lines (57 loc) · 2.17 KB
/
.travis.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
language: go
dist: xenial
sudo: true
services:
- docker
matrix:
allow_failures:
- go: master
include:
- os: linux
go: 1.15.x
cache:
directories:
- "/home/travis/.cache/go-build"
- os: linux
go: master
- os: windows
go: 1.15.x
- os: osx
go: 1.15.x
cache:
directories:
- "/Users/travis/Library/Caches/go-build"
before_install:
- go get -u github.com/client9/misspell/cmd/misspell
- go get -u golang.org/x/lint/golint
- go get -u honnef.co/go/tools/cmd/staticcheck
- go get golang.org/x/tools/cmd/cover
before_script:
- GOFILES=$(find . -type f -name '*.go' | grep -v vendor | grep -v client)
script:
# Just check gofmt on linux, it's the fastest builder
- if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then test -z $(gofmt -s -l $GOFILES); fi
- go test ./... -race -coverprofile=coverage.txt -covermode=atomic
- misspell -error -locale US $GOFILES
- golint -set_exit_status $GOFILES
- staticcheck *.go
- if [[ "$TRAVIS_OS_NAME" == "windows" ]]; then choco install -y mingw; export PATH=/c/tools/mingw64/bin:"$PATH";fi
after_success:
- bash <(curl -s https://codecov.io/bash) -X fix
- make
- make docker
deploy:
provider: releases
api_key:
secure: jhQS1bMTlx/XJShhIYjhfzqbGjKTlnIa6PUIJFMOpV4EstgBRc75WhEjNdCmpgv1BRWlnPu0zEFcmpKgZCf3a2PvAYGNOT/KXb9xOTCSSSobVDcESZf7bPF6pYZ6plKJIKXkPo0kD0RhkE8tOA1Wp+V5VRAFddjn1Atj8DGdPiD8WyKFyLB9RIpEomHqVyULGciq/DNHkyBHGCxMB+JXdq4GfWZL5VMLw5m8HcfHzgAXnqgwyX3UWR8Bg5OlodJMzsYpUaCmoK9mVfe+aLrcCyCQcWcyBIrC3LDhn3yJpg9Al9XEj2QgoqkqB8+c320nRY6/giiXJohre5PvP/G2vNJVlbfxVsA3YV0il3i/X6yL42VysD6ntzCOZkR0gj0kwHmyKcz9aNW10zVukl89CPbFO5Qaqu73WCCbFn9d1/N0OnPepvGlI8VPBGsRbKmDQb7fdL534L2vMp+pSXynoMW6wXZOB50xyXLKXNY6hIYxuA6TOfN4qLZaxb4MfRKnLdiIzD0mAfEWLWmDf4+VrabMMf2X2YlXSBLrtzTKB/dTWsS6PnFUKTmVB+b/SlchDMw18hKrElCGw09SGSII8lk4Mnzu4yuoCvZ6+xkYonWzIX7dFqdTS9jyAKv9XFcNqVVfWAwSMs8Pw0rxwak92psWXumjto60AVdoiqtYddo=
file_glob: true
file:
- bin/rdap-exporter-*
on:
tags: true
repo: adamdecaf/rdap_exporter
go: 1.15.x
skip_cleanup: true
after_deploy:
- echo "$DOCKER_PASSWORD" | docker login -u "$DOCKER_USERNAME" --password-stdin
- make release-push