cargo/ci/azure-install-rust.yml
2019-11-04 16:14:46 -05:00

30 lines
860 B
YAML

steps:
- bash: |
set -e
if command -v rustup; then
echo `command -v rustup` `rustup -V` already installed
rustup self update
else
curl -sSL https://sh.rustup.rs | sh -s -- -y --default-toolchain="$TOOLCHAIN" --profile=minimal
echo "##vso[task.prependpath]$HOME/.cargo/bin"
fi
displayName: Install rustup
- bash: |
set -e
rustup set profile minimal
rustup component remove --toolchain=$TOOLCHAIN rust-docs || echo "already removed"
rustup update --no-self-update $TOOLCHAIN
if [ "$TOOLCHAIN" = "nightly" ]; then
rustup component add --toolchain=$TOOLCHAIN rustc-dev
fi
rustup default $TOOLCHAIN
displayName: Install rust
- bash: |
set -ex
rustup -V
rustc -Vv
cargo -V
displayName: Query rust and cargo versions