# This file has been generated -- see https://github.com/hvr/multi-ghc-travis language: c sudo: false cache: directories: - $HOME/.cabsnap - $HOME/.cabal/packages before_cache: - rm -fv $HOME/.cabal/packages/hackage.haskell.org/build-reports.log - rm -fv $HOME/.cabal/packages/hackage.haskell.org/00-index.tar matrix: include: - env: CABALVER=1.24 GHCVER=8.2.2 compiler: ": #GHC 8.2.2" addons: {apt: {packages: [cabal-install-1.24,ghc-8.2.2], sources: [hvr-ghc]}} before_install: - unset CC - mkdir -p ~/.local/bin - export PATH=$HOME/.local/bin:/opt/ghc/$GHCVER/bin:/opt/cabal/$CABALVER/bin:$PATH - travis_retry curl -L https://www.stackage.org/stack/linux-x86_64 | tar xz --wildcards --strip-components=1 -C ~/.local/bin '*/stack' install: - cabal --version - echo "$(ghc --version) [$(ghc --print-project-git-commit-id 2> /dev/null || echo '?')]" - if [ -f $HOME/.cabal/packages/hackage.haskell.org/00-index.tar.gz ]; then zcat $HOME/.cabal/packages/hackage.haskell.org/00-index.tar.gz > $HOME/.cabal/packages/hackage.haskell.org/00-index.tar; fi - travis_retry cabal update -v - sed -i 's/^jobs:/-- jobs:/' ${HOME}/.cabal/config # - cabal install --only-dependencies --enable-tests --enable-benchmarks --dry -v > installplan.txt # - stack install macaw-x86 --only-dependencies --test --dry-run -v 2> installplan.txt # - sed -i -e '1,/^Resolving /d' installplan.txt; cat installplan.txt # 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: - travis_wait stack --no-terminal --skip-ghc-check setup - stack --stack-yaml stack.ghc-8.2.2.yaml build macaw-x86 macaw-x86-symbolic - stack --stack-yaml stack.ghc-8.2.2.yaml test macaw-x86 # Check that the resulting source distribution can be built & installed. # If there are no other `.tar.gz` files in `dist`, this can be even simpler: # `cabal install --force-reinstalls dist/*-*.tar.gz` # - SRC_TGZ=$(cabal info . | awk '{print $2;exit}').tar.gz && # (cd dist && cabal install --force-reinstalls "$SRC_TGZ") # EOF