Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use rust-lang/rust linkchecker on CI. #1310

Merged
merged 1 commit into from
Mar 14, 2020
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 11 additions & 10 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,22 +1,23 @@
sudo: false
language: rust
cache: cargo
rust:
- nightly
branches:
only:
- master
before_script:
- |
LATEST=$(cargo search mdbook | grep "^mdbook =" | cut -d '"' -f 2)
INSTALLED=$(cargo install --list | grep "^mdbook " | cut -d v -f 2 | tr -d :)
if [ "$INSTALLED" != "$LATEST" ]; then
if [ "$INSTALLED" != "" ]; then
echo "mdbook '$INSTALLED' is already installed"
fi
echo "Installing mdbook '$LATEST'"
cargo install mdbook --force --vers "$LATEST"
fi
set -ex
rustup --version
rustc -Vv
curl -sSL https://github.com/rust-lang/mdBook/releases/download/v0.3.5/mdbook-v0.3.5-x86_64-unknown-linux-gnu.tar.gz | tar -xz --directory=$HOME/.cargo/bin
mdbook --version
rustup toolchain update nightly -c rust-docs
script:
- mdbook build
- mdbook test
- |
set -e
curl -sSLo linkcheck.sh \
https://raw.githubusercontent.com/rust-lang/rust/master/src/tools/linkchecker/linkcheck.sh
sh linkcheck.sh --all rust-by-example