-
Notifications
You must be signed in to change notification settings - Fork 84
/
.travis.yml
56 lines (48 loc) · 1.14 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
language: go
go: "1.13"
go_import_path: github.com/volkszaehler/mbmd
services:
- docker
cache:
directories:
- $HOME/.cache/go-build
- $HOME/gopath/pkg/mod
notifications:
email:
on_success: never
on_failure: change
env:
global:
- GO111MODULE=on
- GOPROXY=https://proxy.golang.org
- PATH=$HOME/gopath/bin:$PATH
before_install:
# Install linters and misspell
- curl -sfL https://install.goreleaser.com/github.com/golangci/golangci-lint.sh | bash -s -- -b $GOPATH/bin
- golangci-lint --version
- make install
script:
# build
- make
# ensure all changes are committed
- go run main.go doc
- test -z "$(git status --porcelain)" || (git status; git diff; false)
before_deploy:
- curl -sfL https://raw.githubusercontent.com/ldez/seihon/master/godownloader.sh | bash -s -- -b $GOPATH/bin
- seihon --version
- |
if ! [ "$BEFORE_DEPLOY_RUN" ]; then
export BEFORE_DEPLOY_RUN=1;
docker login -u $DOCKER_USER -p $DOCKER_PASS
fi
deploy:
- provider: script
skip_cleanup: true
script: curl -sL https://git.io/goreleaser | bash
on:
tags: true
- provider: script
skip_cleanup: true
script: make publish-images
on:
tags: true