-
Notifications
You must be signed in to change notification settings - Fork 5
/
.travis.yml
53 lines (47 loc) · 1.36 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
# parts of this were adapted from https://github.com/higherkindness/droste/blob/bad7dae60a0c32e66918613068d6713d209cc6b4/.travis.yml
language: nix
sudo: required
stages:
- name: test
- name: release
if: (branch = master AND type = push) OR (tag IS present)
jobs:
include:
- env: TEST="docs"
script: ./scripts/builds.sh docs
- env: TEST="test JVM"
script: ./scripts/builds.sh testJVM
- env: TEST="test JS"
script: ./scripts/builds.sh testJS
- env: TEST="lint"
script: ./scripts/builds.sh lint
- env: TEST="coverage"
script: ./scripts/builds.sh coverage
- stage: release
script: ./scripts/builds.sh release
before_install:
- git fetch --tags
install: |
if [ "$(ls -A $HOME/nix-cache)" ]; then
sudo rm -rf /nix/*
cp -a $HOME/nix-cache/* /nix
fi
# These directories are cached to S3 at the end of the build
cache:
directories:
- $HOME/.sbt/1.0/dependency
- $HOME/.sbt/boot/scala*
- $HOME/.sbt/launchers
- $HOME/.ivy2/cache
- $HOME/.coursier
- $HOME/nix-cache
before_cache:
- du -h -d 1 $HOME/.ivy2/cache
- du -h -d 2 $HOME/.sbt/
- find $HOME/.sbt -name "*.lock" -type f -delete
- find $HOME/.ivy2/cache -name "ivydata-*.properties" -type f -delete
- rm -rf $HOME/.ivy2/local
- |
if [ ! "$(ls -A $HOME/nix-cache)" ]; then
cp -a /nix/* $HOME/nix-cache
fi