Skip to content

Commit

Permalink
Add Travis CI configuration file.
Browse files Browse the repository at this point in the history
Signed-off-by: Magnus Therning <magnus@therning.org>
  • Loading branch information
magthe committed May 10, 2015
1 parent 39a96b4 commit 76e7847
Showing 1 changed file with 32 additions and 0 deletions.
32 changes: 32 additions & 0 deletions .travis.yml
@@ -0,0 +1,32 @@
# must not use `language: haskell` here, since we want to handle the ghc
# versions manually
language: c

# See also https://github.com/hvr/multi-ghc-travis for more information

env:
- CABALVER=1.22 GHCVER=7.10.1
# - CABALVER=head GHCVER=head

before_install:
- travis_retry sudo add-apt-repository -y ppa:hvr/ghc
- travis_retry sudo apt-get update
- travis_retry sudo apt-get install cabal-install-$CABALVER ghc-$GHCVER
- export PATH=/opt/ghc/$GHCVER/bin:/opt/cabal/$CABALVER/bin:$PATH

install:
- cabal --version
- echo "$(ghc --version) [$(ghc --print-project-git-commit-id 2> /dev/null || echo '?')]"
- travis_retry cabal update
- cabal install --only-dependencies --enable-tests

script:
- cabal configure --enable-tests -v2
- cabal build
- cabal test
- cabal check

# check that a generated source-distribution can be built & installed
- cabal sdist
- SRC_TGZ=$(cabal info . | awk '{print $2;exit}').tar.gz &&
(cd dist && cabal install --force-reinstalls "$SRC_TGZ")

0 comments on commit 76e7847

Please sign in to comment.