2019-08-08 12:44:48 +00:00
|
|
|
language: rust
|
|
|
|
|
2019-09-09 07:26:00 +00:00
|
|
|
env:
|
|
|
|
- RUSTFLAGS="-D warnings"
|
|
|
|
|
|
|
|
# Cache the whole `~/.cargo` directory to keep `~/cargo/.crates.toml`.
|
|
|
|
cache:
|
|
|
|
directories:
|
|
|
|
- /home/travis/.cargo
|
|
|
|
|
|
|
|
# Don't cache the cargo registry because it's too big.
|
|
|
|
before_cache:
|
|
|
|
- rm -rf /home/travis/.cargo/registry
|
2019-09-03 07:09:05 +00:00
|
|
|
|
2019-09-12 17:47:21 +00:00
|
|
|
|
|
|
|
branches:
|
|
|
|
only:
|
|
|
|
- master
|
|
|
|
- staging
|
|
|
|
- trying
|
|
|
|
|
2019-08-08 12:44:48 +00:00
|
|
|
matrix:
|
|
|
|
fast_finish: true
|
|
|
|
include:
|
|
|
|
- rust: nightly
|
|
|
|
os: linux
|
2019-09-03 07:09:05 +00:00
|
|
|
|
2019-08-08 12:44:48 +00:00
|
|
|
- rust: nightly
|
|
|
|
os: osx
|
2019-08-18 17:14:27 +00:00
|
|
|
osx_image: xcode9.2
|
2019-09-03 07:09:05 +00:00
|
|
|
|
2019-08-16 19:46:23 +00:00
|
|
|
- rust: nightly-x86_64-pc-windows-msvc
|
|
|
|
os: windows
|
2019-08-08 12:44:48 +00:00
|
|
|
|
2019-09-03 07:09:05 +00:00
|
|
|
- name: fmt
|
|
|
|
rust: nightly
|
|
|
|
os: linux
|
2019-09-06 18:03:26 +00:00
|
|
|
before_script: |
|
|
|
|
if ! rustup component add rustfmt; then
|
|
|
|
target=`curl https://rust-lang.github.io/rustup-components-history/x86_64-unknown-linux-gnu/rustfmt`;
|
|
|
|
echo "'rustfmt' is unavailable on the toolchain 'nightly', use the toolchain 'nightly-$target' instead";
|
|
|
|
rustup toolchain install nightly-$target;
|
|
|
|
rustup default nightly-$target;
|
|
|
|
rustup component add rustfmt;
|
|
|
|
fi
|
2019-09-03 07:09:05 +00:00
|
|
|
script:
|
|
|
|
- cargo fmt --all -- --check
|
|
|
|
|
|
|
|
- name: docs
|
|
|
|
rust: nightly
|
|
|
|
os: linux
|
|
|
|
script:
|
2019-09-27 03:15:56 +00:00
|
|
|
- cargo doc --features docs,unstable
|
2019-09-03 07:09:05 +00:00
|
|
|
|
2019-09-10 10:54:06 +00:00
|
|
|
- name: book
|
|
|
|
rust: nightly
|
|
|
|
os: linux
|
|
|
|
before_script:
|
|
|
|
- test -x $HOME/.cargo/bin/mdbook || ./ci/install-mdbook.sh
|
|
|
|
- cargo build # to find 'extern crate async_std' by `mdbook test`
|
|
|
|
script:
|
|
|
|
- mdbook build docs
|
|
|
|
- mdbook test -L ./target/debug/deps docs
|
2019-08-18 23:35:54 +00:00
|
|
|
|
2019-08-08 12:44:48 +00:00
|
|
|
script:
|
2019-09-21 08:39:56 +00:00
|
|
|
- cargo check --all --benches --bins --examples --tests
|
2019-09-03 07:09:05 +00:00
|
|
|
- cargo check --features unstable --all --benches --bins --examples --tests
|
2019-09-18 20:56:13 +00:00
|
|
|
- cargo test --all --doc --features unstable
|