env:
  - CABALVER=1.20 GHCVER=7.8.4 HAPPYVER=1.19.5 ALEXVER=3.1.4

addons:
  postgresql: "9.3"

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

install:
  - cabal --version
  - ghc --version
  - happy --version
  - alex --version
  - travis_retry cabal update
  - cp secrets.m4.example secrets.m4
  - make
  - cabal update
  - cabal sandbox init
  - cabal install yesod-bin
  - export PATH=$(pwd)/.cabal-sandbox/bin:$PATH
  - cabal install --enable-tests --reorder-goals --max-backjumps=-1 -fdev -j
  - ls $(pwd)/.cabal-sandbox/bin

before_script:
  - psql -c 'create database betty_test;' -U postgres

script:
  - yesod test

env:
  - CABALVER=1.20 GHCVER=7.8.4 HAPPYVER=1.19.5 ALEXVER=3.1.4

addons:
  postgresql: "9.3"

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

install:
  - cabal --version
  - ghc --version
  - happy --version
  - alex --version
  - travis_retry cabal update
  - cp secrets.m4.example secrets.m4
  - make
  - cabal update
  - cabal sandbox init
  - cabal configure -fdev 
  - cabal install yesod-bin
  - export PATH=$(pwd)/.cabal-sandbox/bin:$PATH
  - cabal install --enable-tests --reorder-goals --max-backjumps=-1 -j
  - ls $(pwd)/.cabal-sandbox/bin

before_script:
  - psql -c 'create database betty_test;' -U postgres

script:
  - yesod test

Use 'cabal configure -fdev' to disable SES usage on Travis CI.
Use 'cabal configure -fdev' to disable SES usage on Travis CI.
