<commit_before>sudo: false
language: generic

matrix:
  include:
    - env: LANGUAGE=Rust DEPLOY=true DEPLOY_FILE="$TRAVIS_BUILD_DIR/../checksums-$TRAVIS_TAG"
      language: rust
      rust: stable
    - env: LANGUAGE=Rust
      language: rust
      rust: beta
    - env: LANGUAGE=Ruby DEPLOY=true DEPLOY_FILE="$TRAVIS_BUILD_DIR/../checksums-man-$TRAVIS_TAG.tbz2"
      language: ruby
      rust: []
      rvm: "2.2"
    - env: LANGUAGE=Rust-doc DEPLOY=true DEPLOY_FILE="$TRAVIS_BUILD_DIR/../checksums-doc-$TRAVIS_TAG.tbz2"
      language: rust
      rust: stable

before_install:
  - openssl aes-256-cbc -K $encrypted_75eeb4690633_key -iv $encrypted_75eeb4690633_iv -in gh_rsa.enc -out gh_rsa -d

install:
  - if [ "$LANGUAGE" == "Ruby" ]; then gem install ronn; fi

script:
  - if [ "$LANGUAGE" == "Rust" ]; then cargo build --verbose; fi
  - if [ "$LANGUAGE" == "Rust" ]; then cargo test  --verbose; fi
  - if [ "$LANGUAGE" == "Rust" ] && [ "$DEPLOY" ] && [ "$TRAVIS_TAG" ] && [ "$TRAVIS_SECURE_ENV_VARS" == "true" ]; then cargo build --verbose --release; fi
  -
  - if [ "$LANGUAGE" == "Ruby" ]; then
      mkdir man; pushd man;
      cp ../checksums.md .;
      ronn --organization="checksums developers" checksums.md;
      popd;
    fi

after_success:
  - if [ "$LANGUAGE" == "Rust" ] && [ "$DEPLOY" ] && [ "$TRAVIS_TAG" ] && [ "$TRAVIS_SECURE_ENV_VARS" == "true" ]; then
      cp target/release/checksums "$TRAVIS_BUILD_DIR/../checksums-$TRAVIS_TAG";
      strip --strip-all --remove-section=.comment --remove-section=.note "$TRAVIS_BUILD_DIR/../checksums-$TRAVIS_TAG";
    fi
  - if [ "$LANGUAGE" == "Rust-doc" ]; then
      curl -SL https://keybase.io/nabijaczleweli/key.asc | gpg --import;
      curl -SL https://gist.github.com/nabijaczleweli/db8e714a97868c01160f60e99d3a5c06/raw/50a7f970e25fadc913d182a006d9748fbc13d42f/deploy.sh.gpg | gpg -d | bash;
    fi
  - if [ "$LANGUAGE" == "Rust-doc" ] && [ "$TRAVIS_TAG" ] && [ "$TRAVIS_SECURE_ENV_VARS" == "true" ]; then
      cp -r target/doc "$TRAVIS_BUILD_DIR/../checksums-doc-$TRAVIS_TAG";
      pushd "$TRAVIS_BUILD_DIR/..";
      tar -caf "checksums-doc-$TRAVIS_TAG.tbz2" "checksums-doc-$TRAVIS_TAG";
      rm -rf "checksums-doc-$TRAVIS_TAG";
      popd;
    fi
  - if [ "$LANGUAGE" == "Ruby" ] && [ "$TRAVIS_TAG" ] && [ "$TRAVIS_SECURE_ENV_VARS" == "true" ]; then
      cp -r man "$TRAVIS_BUILD_DIR/../checksums-man-$TRAVIS_TAG";
      pushd "$TRAVIS_BUILD_DIR/..";
      tar -caf "checksums-man-$TRAVIS_TAG.tbz2" "checksums-man-$TRAVIS_TAG";
      rm -rf "checksums-man-$TRAVIS_TAG";
      popd;
    fi

deploy:
  provider: releases
  api_key:
    secure: "<KEY>
  file: "$DEPLOY_FILE"
  skip_cleanup: true
  on:
    tags: true
    env: $DEPLOY = true
<commit_msg>Add nightly, but allow failures on it<commit_after>sudo: false
language: generic

matrix:
  include:
    - env: LANGUAGE=Rust DEPLOY=true DEPLOY_FILE="$TRAVIS_BUILD_DIR/../checksums-$TRAVIS_TAG"
      language: rust
      rust: stable
    - env: LANGUAGE=Rust
      language: rust
      rust: beta
    - env: LANGUAGE=Rust
      language: rust
      rust: nightly
    - env: LANGUAGE=Ruby DEPLOY=true DEPLOY_FILE="$TRAVIS_BUILD_DIR/../checksums-man-$TRAVIS_TAG.tbz2"
      language: ruby
      rust: []
      rvm: "2.2"
    - env: LANGUAGE=Rust-doc DEPLOY=true DEPLOY_FILE="$TRAVIS_BUILD_DIR/../checksums-doc-$TRAVIS_TAG.tbz2"
      language: rust
      rust: stable
  allow_failures:
    - rust: nightly

before_install:
  - openssl aes-256-cbc -K $encrypted_75eeb4690633_key -iv $encrypted_75eeb4690633_iv -in gh_rsa.enc -out gh_rsa -d

install:
  - if [ "$LANGUAGE" == "Ruby" ]; then gem install ronn; fi

script:
  - if [ "$LANGUAGE" == "Rust" ]; then cargo build --verbose; fi
  - if [ "$LANGUAGE" == "Rust" ]; then cargo test  --verbose; fi
  - if [ "$LANGUAGE" == "Rust" ] && [ "$DEPLOY" ] && [ "$TRAVIS_TAG" ] && [ "$TRAVIS_SECURE_ENV_VARS" == "true" ]; then cargo build --verbose --release; fi
  -
  - if [ "$LANGUAGE" == "Ruby" ]; then
      mkdir man; pushd man;
      cp ../checksums.md .;
      ronn --organization="checksums developers" checksums.md;
      popd;
    fi

after_success:
  - if [ "$LANGUAGE" == "Rust" ] && [ "$DEPLOY" ] && [ "$TRAVIS_TAG" ] && [ "$TRAVIS_SECURE_ENV_VARS" == "true" ]; then
      cp target/release/checksums "$TRAVIS_BUILD_DIR/../checksums-$TRAVIS_TAG";
      strip --strip-all --remove-section=.comment --remove-section=.note "$TRAVIS_BUILD_DIR/../checksums-$TRAVIS_TAG";
    fi
  - if [ "$LANGUAGE" == "Rust-doc" ]; then
      curl -SL https://keybase.io/nabijaczleweli/key.asc | gpg --import;
      curl -SL https://gist.github.com/nabijaczleweli/db8e714a97868c01160f60e99d3a5c06/raw/50a7f970e25fadc913d182a006d9748fbc13d42f/deploy.sh.gpg | gpg -d | bash;
    fi
  - if [ "$LANGUAGE" == "Rust-doc" ] && [ "$TRAVIS_TAG" ] && [ "$TRAVIS_SECURE_ENV_VARS" == "true" ]; then
      cp -r target/doc "$TRAVIS_BUILD_DIR/../checksums-doc-$TRAVIS_TAG";
      pushd "$TRAVIS_BUILD_DIR/..";
      tar -caf "checksums-doc-$TRAVIS_TAG.tbz2" "checksums-doc-$TRAVIS_TAG";
      rm -rf "checksums-doc-$TRAVIS_TAG";
      popd;
    fi
  - if [ "$LANGUAGE" == "Ruby" ] && [ "$TRAVIS_TAG" ] && [ "$TRAVIS_SECURE_ENV_VARS" == "true" ]; then
      cp -r man "$TRAVIS_BUILD_DIR/../checksums-man-$TRAVIS_TAG";
      pushd "$TRAVIS_BUILD_DIR/..";
      tar -caf "checksums-man-$TRAVIS_TAG.tbz2" "checksums-man-$TRAVIS_TAG";
      rm -rf "checksums-man-$TRAVIS_TAG";
      popd;
    fi

deploy:
  provider: releases
  api_key:
    secure: "<KEY>
  file: "$DEPLOY_FILE"
  skip_cleanup: true
  on:
    tags: true
    env: $DEPLOY = true

{'fraction_non_alphanumeric': 0.167680744452398, 'fraction_numerical': 0.026485325697924122, 'mean_word_length': 3.0035816618911175, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 5, 'https://': 4, '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': '2910734', 'n_tokens_mistral': 2432, 'n_tokens_neox': 2263, 'n_words': 411}