wasmi/doc.sh

19 lines
350 B
Bash
Executable File

#!/usr/bin/env bash
set -eux
cd $(dirname $0)
if [ -s NIGHTLY_TOOLCHAIN ]; then
rustup run $NIGHTLY_TOOLCHAIN cargo doc
else
cargo doc
fi;
# cargo-deadlinks will check any links in docs generated by `cargo doc`.
# This is useful as rustdoc uses raw links which are error prone.
command -v cargo-deadlinks &> /dev/null &&
cargo deadlinks
cd -