# vim: nospell
#
# Basic template to test with GHC=[7.8, 7.10, 8.0]. Caches the 'stack' build
# directory to speed subsequent compilations.
#
# https://docs.travis-ci.com/user/reference/overview/
#
language: minimal
dist: trusty
sudo: true # more storage available on sudo-enabled instances
cache:
directories:
- $HOME/.stack/snapshots
- .stack-work/install
before_cache:
- rm -rf $(stack path --local-install-root)/doc
addons:
apt:
sources: &apt_sources
- hvr-ghc
- ubuntu-toolchain-r-test
packages: &apt_packages
- libgmp-dev
- happy-1.19.5
- alex-3.1.7
matrix:
include:
- env: GHC=7.10.3 CABAL=1.24
compiler: "GHC 7.10"
addons: { apt: { sources: [ *apt_sources ], packages: [ *apt_packages, cabal-install-1.24 ] }}
- env: GHC=8.0.2 CABAL=1.24
compiler: "GHC 8.0"
addons: { apt: { sources: [ *apt_sources ], packages: [ *apt_packages, cabal-install-1.24 ] }}
- env: GHC=8.2.2 CABAL=2.0
compiler: "GHC 8.2"
addons: { apt: { sources: [ *apt_sources ], packages: [ *apt_packages, cabal-install-2.0 ] }}
- env: GHC=8.4.1 CABAL=2.0
compiler: "GHC 8.4"
addons: { apt: { sources: [ *apt_sources ], packages: [ *apt_packages, cabal-install-2.0 ] }}
# - env: GHC=head CABAL=head
# compiler: "GHC HEAD"
# addons: { apt: { sources: [ *apt_sources ], packages: [ *apt_packages, ghc-head, cabal-install-head ] }}
# allow_failures:
# - env: GHC=head CABAL=head
fast_finish: true
before_install:
- export PATH=/opt/cabal/$CABAL/bin:/opt/alex/3.1.7/bin:/opt/happy/1.19.5/bin:$HOME/.cabal/bin:$PATH
- source .travis/install-stack.sh
install:
- echo "$(ghc --version) [$(ghc --print-project-git-commit-id 2> /dev/null || echo '?')]"
- cabal --version
- stack --version
- stack build --no-terminal --dry-run
- travis_retry travis_wait 60 stack build --fast --test --only-dependencies --no-terminal --no-copy-bins
script:
- stack build --no-terminal --fast --test --haddock --no-haddock-deps --no-run-tests
- stack test
after_success:
- source .travis/update-accelerate-buildbot.sh
notifications:
irc:
channels:
- "irc.freenode.org#haskell-lens"
skip_join: true
template:
- "\x0313linear-accelerate\x03/\x0306%{branch}\x03 \x0314%{commit}\x03 %{build_url} %{message}"