forked from src-d/go-license-detector
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
66 lines (57 loc) · 1.43 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
59
60
61
62
63
64
65
66
dist: trusty
language: go
go_import_path: gopkg.in/src-d/go-license-detector.v3
go:
- 1.11.x
- 1.12.x
- 1.13.x
matrix:
fast_finish: true
before_install:
- go get -v golang.org/x/lint/golint
- go get -v github.com/haya14busa/goverage
install:
- export GO111MODULE=on
- make
- go mod vendor
- go build -v gopkg.in/src-d/go-license-detector.v3/cmd/license-detector
script:
- go vet ./...
- lint_warns=$(golint ./... | grep -v vendor/) || true
- if [ ! -z "$lint_warns" ]; then echo "$lint_warns"; exit 1; fi
- goverage -coverprofile=coverage.txt -covermode=count gopkg.in/src-d/go-license-detector.v3/...
- sed -i '/assets/d' coverage.txt
after_success:
- bash <(curl -s https://codecov.io/bash)
jobs:
include:
- stage: deploy
os: osx
go: 1.13.x
after_success:
- gzip -S .darwin_amd64.gz license-detector
script: skip
deploy:
provider: releases
api_key:
secure: $GITHUB_TOKEN
file: "license-detector.darwin_amd64.gz"
skip_cleanup: true
on:
tags: true
- stage: deploy
os: linux
go: 1.13.x
script: skip
after_success:
- gzip -S .linux_amd64.gz license-detector
deploy:
provider: releases
api_key:
secure: $GITHUB_TOKEN
file: "license-detector.linux_amd64.gz"
skip_cleanup: true
on:
tags: true
notifications:
email: false