<commit_before>language: c
sudo: false

cache:
  directories:
  - $HOME/.ghc
  - $HOME/.cabal
  - $HOME/.stack

matrix:
  include:
  - env: BUILD=cabal GHCVER=7.4.1 CABALVER=1.24
    compiler: ": #GHC 7.4.1"
    addons: {apt: {packages: [cabal-install-1.24,ghc-7.4.1], sources: [hvr-ghc]}}
  - env: BUILD=cabal GHCVER=7.4.2 CABALVER=1.24
    compiler: ": #GHC 7.4.2"
    addons: {apt: {packages: [cabal-install-1.24,ghc-7.4.2], sources: [hvr-ghc]}}
  # we have to use CABALVER=1.16 for GHC<7.6 as well, as there's
  # no package for earlier cabal versions in the PPA
  #- env: BUILD=cabal GHCVER=7.6.1 CABALVER=1.16
  #  compiler: ": #GHC 7.6.1"
  #  addons: {apt: {packages: [cabal-install-1.16,ghc-7.6.1], sources: [hvr-ghc]}}
  - env: BUILD=cabal GHCVER=7.6.2 CABALVER=1.24
    compiler: ": #GHC 7.6.2"
    addons: {apt: {packages: [cabal-install-1.24,ghc-7.6.2], sources: [hvr-ghc]}}
  - env: BUILD=cabal GHCVER=7.6.3 CABALVER=1.24
    compiler: ": #GHC 7.6.3"
    addons: {apt: {packages: [cabal-install-1.24,ghc-7.6.3], sources: [hvr-ghc]}}
  - env: BUILD=cabal GHCVER=7.8.4 CABALVER=1.24
    compiler: ": #GHC 7.8.4"
    addons: {apt: {packages: [cabal-install-1.24,ghc-7.8.4], sources: [hvr-ghc]}}
  - env: BUILD=cabal GHCVER=7.10.1 CABALVER=1.24
    compiler: ": #GHC 7.10.1"
    addons: {apt: {packages: [cabal-install-1.24,ghc-7.10.1], sources: [hvr-ghc]}}
  - env: BUILD=cabal GHCVER=7.10.2 CABALVER=1.24
    compiler: ": #GHC 7.10.2"
    addons: {apt: {packages: [cabal-install-1.24,ghc-7.10.2], sources: [hvr-ghc]}}
  - env: BUILD=cabal GHCVER=7.10.3 CABALVER=1.24
    compiler: ": #GHC 7.10.3"
    addons: {apt: {packages: [cabal-install-1.24,ghc-7.10.3], sources: [hvr-ghc]}}

  - env: BUILD=cabal GHCVER=head  CABALVER=head
    compiler: ": #GHC HEAD"
    addons: {apt: {packages: [cabal-install-head,ghc-head], sources: [hvr-ghc]}}

  - env: BUILD=stack ARGS="--resolver lts-2"
    compiler: ": #stack 7.8.4"
    addons: {apt: {packages: [ghc-7.8.4], sources: [hvr-ghc]}}

  - env: BUILD=stack ARGS="--resolver lts-3"
    compiler: ": #stack 7.10.2"
    addons: {apt: {packages: [ghc-7.10.2], sources: [hvr-ghc]}}

  - env: BUILD=stack ARGS="--resolver lts-5"
    compiler: ": #stack 7.10.3"
    addons: {apt: {packages: [ghc-7.10.3], sources: [hvr-ghc]}}

  - env: BUILD=stack ARGS="--resolver nightly"
    compiler: ": #stack nightly"
    addons: {apt: {packages: [libgmp-dev]}}

  - env: BUILD=stack ARGS="--resolver lts-2"
    compiler: ": #stack 7.8.4 osx"
    os: osx

  - env: BUILD=stack ARGS="--resolver lts-3"
    compiler: ": #stack 7.10.2 osx"
    os: osx

  - env: BUILD=stack ARGS="--resolver lts-5"
    compiler: ": #stack 7.10.3 osx"
    os: osx

  - env: BUILD=stack ARGS="--resolver nightly"
    compiler: ": #stack nightly osx"
    os: osx

  allow_failures:
  - env: BUILD=cabal GHCVER=head  CABALVER=head
  - env: BUILD=stack ARGS="--resolver nightly"

before_install:
 - unset CC
 - export PATH=/opt/ghc/$GHCVER/bin:/opt/cabal/$CABALVER/bin:$HOME/.local/bin:$PATH
 - mkdir -p ~/.local/bin
 - |
   if [ `uname` = "Darwin" ];
   then
     curl --insecure -L https://www.stackage.org/stack/osx-x86_64 | tar xz --strip-components=1 --include '*/stack' -C ~/.local/bin;
   else
     curl -L https://www.stackage.org/stack/linux-x86_64 | tar xz --wildcards --strip-components=1 -C ~/.local/bin '*/stack';
   fi

 - |
   echo 'remote-repo: hackage.haskell.org:http://hackage.fpcomplete.com/' > $HOME/.cabal/config
   echo 'remote-repo-cache: $HOME/.cabal/packages' >> $HOME/.cabal/config

   if [ "$CABALVER" != "1.16" ]
   then
     echo 'jobs: $ncpus' >> $HOME/.cabal/config
   fi

   echo 'constraint: Cabal installed' >> $HOME/.cabal/config
   echo 'constraint: array installed' >> $HOME/.cabal/config
   echo 'constraint: base installed' >> $HOME/.cabal/config
   echo 'constraint: bin-package-db installed' >> $HOME/.cabal/config
   echo 'constraint: binary installed' >> $HOME/.cabal/config
   echo 'constraint: bytestring installed' >> $HOME/.cabal/config
   echo 'constraint: containers installed' >> $HOME/.cabal/config
   echo 'constraint: deepseq installed' >> $HOME/.cabal/config
   echo 'constraint: directory installed' >> $HOME/.cabal/config
   echo 'constraint: filepath installed' >> $HOME/.cabal/config
   echo 'constraint: ghc installed' >> $HOME/.cabal/config
   echo 'constraint: ghc-prim installed' >> $HOME/.cabal/config
   echo 'constraint: haskeline installed' >> $HOME/.cabal/config
   echo 'constraint: hoopl installed' >> $HOME/.cabal/config
   echo 'constraint: hpc installed' >> $HOME/.cabal/config
   echo 'constraint: integer-gmp installed' >> $HOME/.cabal/config
   echo 'constraint: integer-simple installed' >> $HOME/.cabal/config
   echo 'constraint: pretty installed' >> $HOME/.cabal/config
   echo 'constraint: process installed' >> $HOME/.cabal/config
   echo 'constraint: rts installed' >> $HOME/.cabal/config
   echo 'constraint: template-haskell installed' >> $HOME/.cabal/config
   echo 'constraint: terminfo installed' >> $HOME/.cabal/config
   echo 'constraint: time installed' >> $HOME/.cabal/config
   echo 'constraint: transformers installed' >> $HOME/.cabal/config
   echo 'constraint: unix installed' >> $HOME/.cabal/config
   echo 'constraint: xhtml installed' >> $HOME/.cabal/config

install:
 - echo "$(ghc --version) [$(ghc --print-project-git-commit-id 2> /dev/null || echo '?')]"
 - if [ -f configure.ac ]; then autoreconf -i; fi
 - |<commit_msg>no transformers?<commit_after>language: c
sudo: false

cache:
  directories:
  - $HOME/.ghc
  - $HOME/.cabal
  - $HOME/.stack

matrix:
  include:
  - env: BUILD=cabal GHCVER=7.4.1 CABALVER=1.24
    compiler: ": #GHC 7.4.1"
    addons: {apt: {packages: [cabal-install-1.24,ghc-7.4.1], sources: [hvr-ghc]}}
  - env: BUILD=cabal GHCVER=7.4.2 CABALVER=1.24
    compiler: ": #GHC 7.4.2"
    addons: {apt: {packages: [cabal-install-1.24,ghc-7.4.2], sources: [hvr-ghc]}}
  # we have to use CABALVER=1.16 for GHC<7.6 as well, as there's
  # no package for earlier cabal versions in the PPA
  #- env: BUILD=cabal GHCVER=7.6.1 CABALVER=1.16
  #  compiler: ": #GHC 7.6.1"
  #  addons: {apt: {packages: [cabal-install-1.16,ghc-7.6.1], sources: [hvr-ghc]}}
  - env: BUILD=cabal GHCVER=7.6.2 CABALVER=1.24
    compiler: ": #GHC 7.6.2"
    addons: {apt: {packages: [cabal-install-1.24,ghc-7.6.2], sources: [hvr-ghc]}}
  - env: BUILD=cabal GHCVER=7.6.3 CABALVER=1.24
    compiler: ": #GHC 7.6.3"
    addons: {apt: {packages: [cabal-install-1.24,ghc-7.6.3], sources: [hvr-ghc]}}
  - env: BUILD=cabal GHCVER=7.8.4 CABALVER=1.24
    compiler: ": #GHC 7.8.4"
    addons: {apt: {packages: [cabal-install-1.24,ghc-7.8.4], sources: [hvr-ghc]}}
  - env: BUILD=cabal GHCVER=7.10.1 CABALVER=1.24
    compiler: ": #GHC 7.10.1"
    addons: {apt: {packages: [cabal-install-1.24,ghc-7.10.1], sources: [hvr-ghc]}}
  - env: BUILD=cabal GHCVER=7.10.2 CABALVER=1.24
    compiler: ": #GHC 7.10.2"
    addons: {apt: {packages: [cabal-install-1.24,ghc-7.10.2], sources: [hvr-ghc]}}
  - env: BUILD=cabal GHCVER=7.10.3 CABALVER=1.24
    compiler: ": #GHC 7.10.3"
    addons: {apt: {packages: [cabal-install-1.24,ghc-7.10.3], sources: [hvr-ghc]}}

  - env: BUILD=cabal GHCVER=head  CABALVER=head
    compiler: ": #GHC HEAD"
    addons: {apt: {packages: [cabal-install-head,ghc-head], sources: [hvr-ghc]}}

  - env: BUILD=stack ARGS="--resolver lts-2"
    compiler: ": #stack 7.8.4"
    addons: {apt: {packages: [ghc-7.8.4], sources: [hvr-ghc]}}

  - env: BUILD=stack ARGS="--resolver lts-3"
    compiler: ": #stack 7.10.2"
    addons: {apt: {packages: [ghc-7.10.2], sources: [hvr-ghc]}}

  - env: BUILD=stack ARGS="--resolver lts-5"
    compiler: ": #stack 7.10.3"
    addons: {apt: {packages: [ghc-7.10.3], sources: [hvr-ghc]}}

  - env: BUILD=stack ARGS="--resolver nightly"
    compiler: ": #stack nightly"
    addons: {apt: {packages: [libgmp-dev]}}

  - env: BUILD=stack ARGS="--resolver lts-2"
    compiler: ": #stack 7.8.4 osx"
    os: osx

  - env: BUILD=stack ARGS="--resolver lts-3"
    compiler: ": #stack 7.10.2 osx"
    os: osx

  - env: BUILD=stack ARGS="--resolver lts-5"
    compiler: ": #stack 7.10.3 osx"
    os: osx

  - env: BUILD=stack ARGS="--resolver nightly"
    compiler: ": #stack nightly osx"
    os: osx

  allow_failures:
  - env: BUILD=cabal GHCVER=head  CABALVER=head
  - env: BUILD=stack ARGS="--resolver nightly"

before_install:
 - unset CC
 - export PATH=/opt/ghc/$GHCVER/bin:/opt/cabal/$CABALVER/bin:$HOME/.local/bin:$PATH
 - mkdir -p ~/.local/bin
 - |
   if [ `uname` = "Darwin" ];
   then
     curl --insecure -L https://www.stackage.org/stack/osx-x86_64 | tar xz --strip-components=1 --include '*/stack' -C ~/.local/bin;
   else
     curl -L https://www.stackage.org/stack/linux-x86_64 | tar xz --wildcards --strip-components=1 -C ~/.local/bin '*/stack';
   fi

 - |
   echo 'remote-repo: hackage.haskell.org:http://hackage.fpcomplete.com/' > $HOME/.cabal/config
   echo 'remote-repo-cache: $HOME/.cabal/packages' >> $HOME/.cabal/config

   if [ "$CABALVER" != "1.16" ]
   then
     echo 'jobs: $ncpus' >> $HOME/.cabal/config
   fi

   echo 'constraint: Cabal installed' >> $HOME/.cabal/config
   echo 'constraint: array installed' >> $HOME/.cabal/config
   echo 'constraint: base installed' >> $HOME/.cabal/config
   echo 'constraint: bin-package-db installed' >> $HOME/.cabal/config
   echo 'constraint: binary installed' >> $HOME/.cabal/config
   echo 'constraint: bytestring installed' >> $HOME/.cabal/config
   echo 'constraint: containers installed' >> $HOME/.cabal/config
   echo 'constraint: deepseq installed' >> $HOME/.cabal/config
   echo 'constraint: directory installed' >> $HOME/.cabal/config
   echo 'constraint: filepath installed' >> $HOME/.cabal/config
   echo 'constraint: ghc installed' >> $HOME/.cabal/config
   echo 'constraint: ghc-prim installed' >> $HOME/.cabal/config
   echo 'constraint: haskeline installed' >> $HOME/.cabal/config
   echo 'constraint: hoopl installed' >> $HOME/.cabal/config
   echo 'constraint: hpc installed' >> $HOME/.cabal/config
   echo 'constraint: integer-gmp installed' >> $HOME/.cabal/config
   echo 'constraint: integer-simple installed' >> $HOME/.cabal/config
   echo 'constraint: pretty installed' >> $HOME/.cabal/config
   echo 'constraint: process installed' >> $HOME/.cabal/config
   echo 'constraint: rts installed' >> $HOME/.cabal/config
   echo 'constraint: template-haskell installed' >> $HOME/.cabal/config
   echo 'constraint: terminfo installed' >> $HOME/.cabal/config
   echo 'constraint: time installed' >> $HOME/.cabal/config
   echo 'constraint: unix installed' >> $HOME/.cabal/config
   echo 'constraint: xhtml installed' >> $HOME/.cabal/config

install:
 - echo "$(ghc --version) [$(ghc --print-project-git-commit-id 2> /dev/null || echo '?')]"
 - if [ -f configure.ac ]; then autoreconf -i; fi
 - |
{'fraction_non_alphanumeric': 0.18617562690848524, 'fraction_numerical': 0.037383177570093455, 'mean_word_length': 3.265193370165746, 'pattern_counts': {'":': 36, '<': 5, '<?xml version=': 0, '>': 117, 'https://': 4, 'lorem ipsum': 0, 'www.': 4, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 1, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2295916', 'n_tokens_mistral': 4573, 'n_tokens_neox': 4384, 'n_words': 912}