<commit_before>sudo: false

language: rust

matrix:
  fast_finish: true
  include:
  - rust: nightly
  - rust: beta
  - rust: stable
  allow_failures:
  - rust: nightly

script:
- RUSTFLAGS="$RUSTFLAGS -C link-dead-code" cargo test

cache:
  cargo: true
  apt: true
  directories:
  - target/debug/deps
  - target/debug/build

addons:
  apt:
    packages:
    - libcurl4-openssl-dev
    - libelf-dev
    - libdw-dev
    - cmake
    - gcc
    - binutils-dev # required for `kcov --verify`

after_success: |
  [ $TRAVIS_RUST_VERSION = stable ] &&
  [ $TRAVIS_BRANCH = master ] &&
  [ $TRAVIS_PULL_REQUEST = false ] &&
  (wget https://github.com/SimonKagstrom/kcov/archive/master.tar.gz &&
  tar xzf master.tar.gz && mkdir kcov-master/build && cd kcov-master/build && cmake .. && make && make install DESTDIR=../tmp && cd ../.. &&
  ls target/debug &&
  for file in target/debug/rainbowcoat-*; do mkdir -p "target/cov/$(basename $file)"; ./kcov-master/tmp/usr/local/bin/kcov --exclude-pattern=/.cargo,/usr/lib --verify "target/cov/$(basename $file)" "$file"; done &&
  echo "covered") || true &&
  cargo doc --no-deps &&
  echo "<meta http-equiv=refresh content=0;url=`echo $TRAVIS_REPO_SLUG | cut -d '/' -f 2`/index.html>" > target/doc/index.html &&
  pip install --user ghp-import &&
  /home/travis/.local/bin/ghp-import -n target/doc &&<commit_msg>travis config<commit_after>sudo: false

language: rust

matrix:
  fast_finish: true
  include:
  - rust: nightly
  - rust: beta
  - rust: stable
  allow_failures:
  - rust: nightly

script:
- RUSTFLAGS="$RUSTFLAGS -C link-dead-code" cargo test

cache:
  cargo: true
  apt: true
  directories:
  - target/debug/deps
  - target/debug/build

addons:
  apt:
    packages:
      - libcurl4-openssl-dev
      - libelf-dev
      - libdw-dev
      - binutils-dev
      - libiberty-dev

after_success: |
  [ $TRAVIS_RUST_VERSION = stable ] &&
  [ $TRAVIS_BRANCH = master ] &&
  [ $TRAVIS_PULL_REQUEST = false ] &&
  (wget https://github.com/SimonKagstrom/kcov/archive/master.tar.gz &&
  tar xzf master.tar.gz && mkdir kcov-master/build && cd kcov-master/build && cmake .. && make && make install DESTDIR=../tmp && cd ../.. &&
  ls target/debug &&
  for file in target/debug/rainbowcoat-*; do mkdir -p "target/cov/$(basename $file)"; ./kcov-master/tmp/usr/local/bin/kcov --exclude-pattern=/.cargo,/usr/lib --verify "target/cov/$(basename $file)" "$file"; done &&
  echo "covered") || true &&
  cargo doc --no-deps &&
  echo "<meta http-equiv=refresh content=0;url=`echo $TRAVIS_REPO_SLUG | cut -d '/' -f 2`/index.html>" > target/doc/index.html &&
  pip install --user ghp-import &&
  /home/travis/.local/bin/ghp-import -n target/doc &&
{'fraction_non_alphanumeric': 0.16573138795361017, 'fraction_numerical': 0.002244668911335578, 'mean_word_length': 2.9381443298969074, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 7, 'https://': 2, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5641343', 'n_tokens_mistral': 1022, 'n_tokens_neox': 1003, 'n_words': 210}