1+ language : c
12sudo : false
2- env :
3- - GHCVER=7.8.4 COVERAGE_SUITE=tests
4- - GHCVER=7.8.4 COVERAGE_SUITE=psci-tests
5- - GHCVER=7.6.3
6- - GHCVER=7.10.1
7- - GHCVER=7.8.4 STACKAGE=lts-2.22
8- # 7.10.2 Pending https://github.com/travis-ci/apt-package-whitelist/pull/686
9- - GHCVER=7.10.1 STACKAGE=lts-3.1
10- - GHCVER=7.10.1 STACKAGE=nightly-2015-08-12
3+ matrix :
4+ include :
5+ - env : GHCVER=7.8.4 COVERAGE_SUITE=tests
6+ compiler : " : #GHC 7.8.4 - tests"
7+ addons : {apt: {packages: [cabal-install-1.22,ghc-7.8.4,happy-1.19.5,alex-3.1.4], sources: [hvr-ghc]}}
8+ - env : GHCVER=7.8.4 COVERAGE_SUITE=psci-tests
9+ compiler : " : #GHC 7.8.4 - psci-tests"
10+ addons : {apt: {packages: [cabal-install-1.22,ghc-7.8.4,happy-1.19.5,alex-3.1.4], sources: [hvr-ghc]}}
11+ - env : GHCVER=7.8.4 STACKAGE=lts-22
12+ compiler : " : #GHC 7.8.4 - lts-2.22"
13+ addons : {apt: {packages: [cabal-install-1.22,ghc-7.8.4,happy-1.19.5,alex-3.1.4], sources: [hvr-ghc]}}
14+ - env : GHCVER=7.6.3
15+ compiler : " : #GHC 7.6.3"
16+ addons : {apt: {packages: [cabal-install-1.22,ghc-7.6.3,happy-1.19.5,alex-3.1.4], sources: [hvr-ghc]}}
17+ - env : GHCVER=7.10.1
18+ compiler : " : #GHC 7.10.1"
19+ addons : {apt: {packages: [cabal-install-1.22,ghc-7.10.1,happy-1.19.5,alex-3.1.4], sources: [hvr-ghc]}}
20+ # 7.10.2 Pending https://github.com/travis-ci/apt-package-whitelist/pull/686
21+ - env : GHCVER=7.10.1 STACKAGE=lts=3.1 RUNSDISTTESTS=YES
22+ compiler : " : #GHC 7.10.1 lts-3.1"
23+ addons : {apt: {packages: [cabal-install-1.22,ghc-7.10.1,happy-1.19.5,alex-3.1.4], sources: [hvr-ghc]}}
24+ - env : GHCVER=7.10.1 STACKAGE=nightly-2015-08-12
25+ compiler : " : #GHC 7.10.1 nightly-2015-08-12"
26+ addons : {apt: {packages: [cabal-install-1.22,ghc-7.10.1,happy-1.19.5,alex-3.1.4], sources: [hvr-ghc]}}
1127before_install :
28+ - unset CC
1229 - export PATH="/opt/ghc/$GHCVER/bin:$PATH"
1330 - export PATH="/opt/cabal/1.22/bin:$PATH"
1431 - export PATH="$HOME/.cabal/bin:$PATH"
@@ -23,13 +40,20 @@ install:
2340 # cabal and ghc tries to use them all. Which is bad idea on a shared box.
2441 # See also: https://ghc.haskell.org/trac/ghc/ticket/9221
2542 - sed -i 's/^jobs:/-- jobs:/' ${HOME}/.cabal/config
26- - mkdir -p sandboxes/$GHCVER/${STACKAGE:-none}
27- - cabal sandbox init --sandbox sandboxes/$GHCVER/${STACKAGE:-none}
28- # Download stackage cabal.config
29- # Not sure whether filtering out purescript is necessary
43+ # Cache sandboxes in ~/cabal-sandboxes
44+ # Move right sandbox to .cabal-sandbox if exists
45+ - if [ -d ~/cabal-sandboxes/$GHCVER-${STACKAGE:-none} ]; then
46+ mv ~/cabal-sandboxes/$GHCVER-${STACKAGE:-none} .cabal-sandbox;
47+ fi
48+ - mkdir -p .cabal-sandbox
49+ - cabal sandbox init --sandbox .cabal-sandbox
50+ # Download stackage cabal.config, not sure whether filtering is necessary
3051 - if [ -n "$STACKAGE" ]; then curl http://www.stackage.org/$STACKAGE/cabal.config | grep -v purescript > cabal.config; fi
3152 - cabal install --only-dependencies --enable-tests
3253 - cabal install hpc-coveralls
54+ # Snapshot state of the sandbox now, so we don't need to make new one for test install
55+ - rm -rf ~/cabal-sandboxes/$GHCVER-${STACKAGE:-none}
56+ - cp -r .cabal-sandbox ~/cabal-sandboxes/$GHCVER-${STACKAGE:-none}
3357script :
3458 - ./travis/configure.sh
3559 - cabal build
@@ -50,18 +74,6 @@ deploy:
5074 on :
5175 all_branches : true
5276 tags : true
53- addons :
54- apt :
55- sources :
56- - hvr-ghc
57- packages :
58- - cabal-install-1.22
59- - ghc-7.6.3
60- - ghc-7.8.4
61- - ghc-7.10.1
62- - happy-1.19.5
63- - alex-3.1.4
6477cache :
6578 directories :
66- - sandboxes/
67- - ../install-test/sandboxes/
79+ - ~/cabal-sandboxes
0 commit comments