-
-
Notifications
You must be signed in to change notification settings - Fork 16
/
.travis.yml
30 lines (30 loc) · 908 Bytes
/
.travis.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
sudo: false
language: rust
rust:
- stable
- beta
os:
- linux
- osx
cache: cargo
before_cache:
- cargo prune
env:
global:
- PATH=$PATH:$HOME/.cargo/bin
- RUST_BACKTRACE=1
before_script:
- |
(which cargo-install-update && cargo install-update cargo-update) || cargo install cargo-update &&
(which cargo-prune && cargo install-update cargo-prune) || cargo install cargo-prune
- rustup component add rustfmt-preview
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then export OPENSSL_INCLUDE_DIR=`brew --prefix openssl`/include; fi
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then export OPENSSL_LIB_DIR=`brew --prefix openssl`/lib; fi
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then export DEP_OPENSSL_INCLUDE=`brew --prefix openssl`/include; fi
script:
- if [ "${TRAVIS_RUST_VERSION}" = stable ]; then
(
cargo fmt -- --check
);
fi
- cargo test --release