travis: remove travis-cargo
This commit is contained in:
parent
5a0713feb9
commit
262eaa8883
32
.travis.yml
32
.travis.yml
|
@ -38,26 +38,34 @@ branches:
|
||||||
|
|
||||||
before_script:
|
before_script:
|
||||||
- export PATH=$HOME/.local/bin:$HOME/.cargo/bin:$PATH
|
- export PATH=$HOME/.local/bin:$HOME/.cargo/bin:$PATH
|
||||||
- pip install 'travis-cargo<0.2' --user
|
- |
|
||||||
- which rustfmt || travis-cargo --only nightly install rustfmt-nightly -- --force
|
if [ $TRAVIS_RUST_VERSION = "nightly" ]; then
|
||||||
- which cargo-install-update || cargo install cargo-update
|
cargo install rustfmt-nightly --force;
|
||||||
- cargo install-update -a
|
fi
|
||||||
- mkdir $(pwd)/socket
|
- mkdir $(pwd)/socket
|
||||||
- export XDG_RUNTIME_DIR="$(pwd)/socket"
|
- export XDG_RUNTIME_DIR="$(pwd)/socket"
|
||||||
|
|
||||||
script:
|
script:
|
||||||
- travis-cargo -q --only nightly fmt -- -- --write-mode=diff
|
- |
|
||||||
- travis-cargo -q --skip nightly test
|
if [ $TRAVIS_RUST_VERSION = "nightly" ]; then
|
||||||
- travis-cargo -q --only nightly test -- --features "clippy"
|
cargo fmt -- --write-mode=diff
|
||||||
- travis-cargo -q --only stable doc -- --no-deps
|
fi
|
||||||
|
- |
|
||||||
|
features=$([ $TRAVIS_RUST_VERSION = "nightly" ] && echo "clippy" || echo "")
|
||||||
|
cargo test --features "$features"
|
||||||
|
- |
|
||||||
|
if [ $TRAVIS_RUST_VERSION = "stable" ]; then
|
||||||
|
cargo doc --no-deps
|
||||||
|
fi
|
||||||
|
|
||||||
after_success:
|
after_success:
|
||||||
- travis-cargo -q --only stable doc-upload
|
- |
|
||||||
|
[ $TRAVIS_RUST_VERSION = "stable" ] &&
|
||||||
|
[ $TRAVIS_BRANCH = "master" ] &&
|
||||||
|
[ $TRAVIS_PULL_REQUEST = "false" ] &&
|
||||||
|
./doc_upload.sh
|
||||||
env:
|
env:
|
||||||
global:
|
global:
|
||||||
# override the default `--features unstable` used for the nightly branch (optional)
|
|
||||||
- TRAVIS_CARGO_NIGHTLY_FEATURE=""
|
|
||||||
- RUST_BACKTRACE=1
|
- RUST_BACKTRACE=1
|
||||||
- secure: lJjdHvIm6Pzimdik+SafO/MOWLLGY5TJdI7hWcwQ4+XNjuwncKx9ZJ8zqr2xClUKSALvUWB+vdu7i9wTWtsOYnDpyy8wuRvBZoaD5c8H2igsnzmGPPtP5KlPi5sEYvcCRY4vf9GDrvZm6tkNwMRsJBJ+2W/dSOTudMQA9mkdQcn5x24HVUBBOKEEuNy5ZOHZIj/+tre3USC8PbVvWyC5HHHjjEMBKR3F/BoaR1BJq2u4BdyDGTkfsoUa1zaTjApcZiEEK9KhoWDentkmlJHJCHKxC/zIZGhNx8ukw2yrms6j1k94jXB3rJP97q8UyNFcCO1HVO46EdLB6sFUPAW0CuDM27xIHDv+FyU3ICZVlpKQIK8YPJuLmQbCJFpVvEgfNfCIm+7+4jDci09FmHhuW+wQrTZDsRbCQz2gtVveeoE9/cZy5qAbI+UW4F25GGg9Ycxn+VOBU6Zdg8T9MLRRbHJXCzjMmJrNwK+6fEnCsMoVxwbRF9Fsh2JXS0PFdQgJSGtYYW31HEUEu4zrUuooJtz4CAgR+vB9oBxHfu6Y9GXZFmTsrUyuvGSl5vFB3AXLK6AP3BeXu3Bq2wQDy7ClQxvxkpN/eCKKxwV9vE9nRY0eD1sc6esv2gTjlV+gqs7V7JL8VvZulzZZ2gk6S/GhImCqyhJTqziKR7RXsPRZ2Zw=
|
- secure: lJjdHvIm6Pzimdik+SafO/MOWLLGY5TJdI7hWcwQ4+XNjuwncKx9ZJ8zqr2xClUKSALvUWB+vdu7i9wTWtsOYnDpyy8wuRvBZoaD5c8H2igsnzmGPPtP5KlPi5sEYvcCRY4vf9GDrvZm6tkNwMRsJBJ+2W/dSOTudMQA9mkdQcn5x24HVUBBOKEEuNy5ZOHZIj/+tre3USC8PbVvWyC5HHHjjEMBKR3F/BoaR1BJq2u4BdyDGTkfsoUa1zaTjApcZiEEK9KhoWDentkmlJHJCHKxC/zIZGhNx8ukw2yrms6j1k94jXB3rJP97q8UyNFcCO1HVO46EdLB6sFUPAW0CuDM27xIHDv+FyU3ICZVlpKQIK8YPJuLmQbCJFpVvEgfNfCIm+7+4jDci09FmHhuW+wQrTZDsRbCQz2gtVveeoE9/cZy5qAbI+UW4F25GGg9Ycxn+VOBU6Zdg8T9MLRRbHJXCzjMmJrNwK+6fEnCsMoVxwbRF9Fsh2JXS0PFdQgJSGtYYW31HEUEu4zrUuooJtz4CAgR+vB9oBxHfu6Y9GXZFmTsrUyuvGSl5vFB3AXLK6AP3BeXu3Bq2wQDy7ClQxvxkpN/eCKKxwV9vE9nRY0eD1sc6esv2gTjlV+gqs7V7JL8VvZulzZZ2gk6S/GhImCqyhJTqziKR7RXsPRZ2Zw=
|
||||||
|
|
||||||
|
|
|
@ -0,0 +1,11 @@
|
||||||
|
#!/bin/sh
|
||||||
|
|
||||||
|
repo="$TRAVIS_REPO_SLUG"
|
||||||
|
token="$GH_TOKEN"
|
||||||
|
commit=$(git rev-parse --short HEAD)
|
||||||
|
msg="Documentation for $repo@$commit"
|
||||||
|
|
||||||
|
git clone https://github.com/davisp/ghp-import
|
||||||
|
./ghp-import/ghp_import.py -n -m "$msg" target/doc
|
||||||
|
# pipe output to /dev/null to avoid printing our token in travis log
|
||||||
|
git push -fq "https://$token@github.com/$repo.git" "gh-pages" > /dev/null
|
Loading…
Reference in New Issue