-
Notifications
You must be signed in to change notification settings - Fork 30
/
Copy path.travis.yml
53 lines (47 loc) · 1.8 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
sudo: required
language: minimal
env:
global:
- GOVERSION=1.13.8
- GOMETALINTER_VERSION=2.0.11
- GITHUB_RELEASE_VERSION=0.7.2
matrix:
include:
- os: linux
services:
- docker
cache:
directories:
- "$HOME/.npm" # npm ci will remove node_modules; this is _its_ download cache
script:
- ./run-in-docker.sh make dep install test api-reference STATIC=yes
- os: osx
osx_image: xcode11.3
cache:
directories:
- "$HOME/.npm" # npm ci will remove node_modules; this is _its_ download cache
before_install:
# v8 prebuilt library
- git clone https://github.com/jkcfg/prebuilt.git
- make -C prebuilt install
# go
- (cd ~ && curl -fsSLO https://dl.google.com/go/go${GOVERSION}.darwin-amd64.tar.gz)
- mkdir ~/go-${GOVERSION} && tar xf ~/go${GOVERSION}.darwin-amd64.tar.gz -C ~/go-${GOVERSION} --strip-components 1
# gometalinter
- (cd ~ && curl -fsSLO https://github.com/alecthomas/gometalinter/releases/download/v${GOMETALINTER_VERSION}/gometalinter-${GOMETALINTER_VERSION}-darwin-amd64.tar.gz)
- tar -xf ~/gometalinter-${GOMETALINTER_VERSION}-darwin-amd64.tar.gz -C /usr/local/bin --strip-components 1
# github-release
- (cd ~ && curl -fsSLO https://github.com/aktau/github-release/releases/download/v${GITHUB_RELEASE_VERSION}/darwin-amd64-github-release.tar.bz2)
- tar -xf ~/darwin-amd64-github-release.tar.bz2 -C /usr/local/bin --strip-components 3
script:
- export PATH=~/go-${GOVERSION}/bin:~/go/bin:$PATH
- make dep install test
deploy:
- skip_cleanup: true
provider: script
script: ./run-deploy.sh
- skip_cleanup: true
provider: script
script: ./run-release.sh $TRAVIS_TAG
on:
tags: true