@@ -1,28 +1,85 @@
1−# Use new container infrastructure to enable caching
2−sudo: false
3−
4−# Choose a lightweight base image; we provide our own build tools.
5−language: c
6−
7−# GHC depends on GMP. You can add other dependencies here as well.
8−addons:
9− apt:
10− packages:
11− - libgmp-dev
12−
13−before_install:
14−# Download and unpack the stack executable
15−- mkdir -p ~/.local/bin
16−- export PATH=$HOME/.local/bin:$PATH
17−- travis_retry curl -L https://www.stackage.org/stack/linux-x86_64 | tar xz --wildcards --strip-components=1 -C ~/.local/bin '*/stack'
18−
19−# This line does all of the work: installs GHC if necessary, builds the
20−# library, executables, and test suites, and runs the test suites.
21−# `--no-terminal works` around some quirks in Travis's terminal implementation.
22−script: stack --no-terminal --install-ghc test
23−
24−# Caching so the next build will be fast too.
1+sudo: true
2+language: generic
3+
4+git:
5+ depth: 5
6+
257cache:
268 directories:
27− - $HOME/.stack
28− - $HOME/build/vrom911/typerep-map/.stack-work
9+ - "$HOME/.cabal"
10+ - "$HOME/.ghc"
11+ - "$HOME/.stack"
12+ - ".stack-work"
13+
14+matrix:
15+
16+ include:
17+
18+ - ghc: 8.0.2
19+ env: GHCVER='8.0.2' CABALVER='head'
20+ os: linux
21+ addons:
22+ apt:
23+ sources:
24+ - hvr-ghc
25+ packages:
26+ - ghc-8.0.2
27+ - cabal-install-head
28+
29+ - ghc: 8.2.2
30+ env: GHCVER='8.2.2' CABALVER='head'
31+ os: linux
32+ addons:
33+ apt:
34+ sources:
35+ - hvr-ghc
36+ packages:
37+ - ghc-8.2.2
38+ - cabal-install-head
39+
40+ - ghc: 8.4.3
41+ env: GHCVER='8.4.3' CABALVER='head'
42+ os: linux
43+ addons:
44+ apt:
45+ sources:
46+ - hvr-ghc
47+ packages:
48+ - ghc-8.4.3
49+ - cabal-install-head
50+
51+ - ghc: 8.4.3
52+ env: STACK_YAML="$HOME/build/vrom911/typerep-map/stack.yaml"
53+ os: linux
54+ addons:
55+ apt:
56+ packages:
57+ - libgmp-dev
58+
59+install:
60+ - |
61+ if [ -z "$STACK_YAML" ]; then
62+ export PATH="/opt/ghc/$GHCVER/bin:/opt/cabal/$CABALVER/bin:$PATH"
63+ echo $PATH
64+ cabal new-update
65+ cabal new-build --enable-tests --enable-benchmarks
66+ else
67+ mkdir -p ~/.local/bin
68+ export PATH="$HOME/.local/bin:$PATH"
69+ travis_retry curl -L 'https://www.stackage.org/stack/linux-x86_64' | tar xz --wildcards --strip-components=1 -C ~/.local/bin '*/stack'
70+ stack --version
71+ stack setup --no-terminal --install-cabal 2.0.1.0
72+ stack ghc -- --version
73+ stack build --only-dependencies --no-terminal
74+ fi
75+
76+script:
77+ - |
78+ if [ -z "$STACK_YAML" ]; then
79+ cabal new-test
80+ else
81+ stack build --test --bench --no-terminal
82+ fi
83+
84+notifications:
85+ email: false