xorstream 1.0.0

Utility for xoring a vector of data with a stream of data
Documentation
stages:
  - build
  - deploy

rust-latest:
  stage: build
  image: rust:latest
  cache:
    key: latest
    paths:
    - target
  script:
    - cargo build --verbose
    - cargo test --verbose

rust-nightly:
  stage: build
  image: rustlang/rust:nightly
  cache:
    key: nighty
    paths:
    - target
  script:
    - cargo build --verbose
    - cargo test --verbose
  allow_failure: true

pages:
  stage: deploy
  image: rustlang/rust:nightly
  cache:
    key: pages
    paths:
    - target
  script:
    - PATH="$PATH:$(pwd)/target/bin"
    - maybe_install(){ if ! ($1 --help); then cargo install $1 --root target --force; fi; }
    - time maybe_install static-compress
    - time maybe_install cargo-tarpaulin
    - time maybe_install oxipng
    - "# Finished install, generate docs"
    - cargo doc --all --document-private-items --verbose
    - cp -r target/doc public
    - echo 'Redirecting to xorstream...<link rel="prerender" href="xorstream/index.html"/><meta http-equiv="refresh" content="3; url=xorstream/index.html"/><link rel=prefetch href=rustdoc.css /><link rel=prefetch href=normalize.css /><link rel=prefetch href=rust-logo.png />' > public/index.html
    - "# Compressing doc resources"
    - COMPRESS='public/**/*.{html,css,js,svg,txt}'
    - time static-compress -j 4 -c brotli -q 11 "$COMPRESS"
    - time static-compress -j 4 -c gzip -q 9 "$COMPRESS"
    - time oxipng -Z $(find public -name '*.png')
    - "# Checking code coverage"
    - cargo-tarpaulin
  allow_failure: false
  artifacts:
    paths:
    - public
  only:
  - master