-
Notifications
You must be signed in to change notification settings - Fork 21
/
Copy path.travis.yml
59 lines (50 loc) · 1.97 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
language: generic
# Use the docker infrastructure
sudo: false
# Cache the installed Haskell stuff
cache:
directories:
- $HOME/.stack
notifications:
email:
on_success: change
on_failure: change
# The following enables several GHC versions to be tested; often it's enough to
# test only against the last release in a major GHC version. Feel free to omit
# lines listings versions you don't need/want testing for.
env:
global:
- PKG_CONFIG_PATH=$HOME/.stack/local/lib/pkgconfig
- LD_LIBRARY_PATH=$HOME/.stack/local/lib
- LD_RUN_PATH=$HOME/.stack/local/lib
- CFLAGS=-I$HOME/.stack/local/include
- LDFLAGS=-L$HOME/.stack/local/lib
matrix:
- STACK_RESOLVER=lts-11
- STACK_RESOLVER=lts-12
- STACK_RESOLVER=lts-13
- STACK_RESOLVER=lts-14
- STACK_RESOLVER=nightly
matrix:
fast_finish: true
allow_failures:
- env: STACK_RESOLVER=nightly
# Download the latest stack command.
before_install:
- travis_retry wget https://www.stackage.org/stack/linux-x86_64
- tar -xvf linux-x86_64
- mv stack-*-linux-x86_64/stack stack
- travis_retry ./stack --no-terminal --resolver $STACK_RESOLVER setup
install:
- echo "$(ghc --version) [$(ghc --print-project-git-commit-id 2> /dev/null || echo '?')]"
# Here starts the actual work to be performed for the package under test; any
# command which exits with a non-zero exit code causes the build to fail.
script:
- ./stack --no-terminal --resolver $STACK_RESOLVER sdist
- tar -xzf $(./stack --no-terminal --resolver $STACK_RESOLVER path --dist-dir)/aeson-diff-*.tar.gz
- cd aeson-diff-*
- travis_retry ../stack --no-terminal --resolver $STACK_RESOLVER setup
- travis_retry ../stack --no-terminal --resolver $STACK_RESOLVER install --only-snapshot -j4 --verbosity info
- ../stack --no-terminal --resolver $STACK_RESOLVER build
- ../stack --no-terminal --resolver $STACK_RESOLVER haddock --no-haddock-deps
- ../stack --no-terminal --resolver $STACK_RESOLVER test