summaryrefslogtreecommitdiff
path: root/cc/ci/azure-install-rust.yml
diff options
context:
space:
mode:
Diffstat (limited to 'cc/ci/azure-install-rust.yml')
-rw-r--r--cc/ci/azure-install-rust.yml24
1 files changed, 24 insertions, 0 deletions
diff --git a/cc/ci/azure-install-rust.yml b/cc/ci/azure-install-rust.yml
new file mode 100644
index 0000000..118d65e
--- /dev/null
+++ b/cc/ci/azure-install-rust.yml
@@ -0,0 +1,24 @@
+steps:
+ - bash: |
+ set -e
+ toolchain=$TOOLCHAIN
+ if [ "$toolchain" = "" ]; then
+ toolchain=stable
+ fi
+ curl https://sh.rustup.rs -sSf | sh -s -- -y --default-toolchain $toolchain
+ echo "##vso[task.prependpath]$HOME/.cargo/bin"
+ displayName: Install rust (unix)
+ condition: ne( variables['Agent.OS'], 'Windows_NT' )
+
+ - script: |
+ IF "%TOOLCHAIN%"=="" (SET TOOLCHAIN=stable-%TARGET%)
+ curl -sSf -o rustup-init.exe https://win.rustup.rs
+ rustup-init.exe -y --default-toolchain %TOOLCHAIN%
+ echo ##vso[task.prependpath]%USERPROFILE%\.cargo\bin
+ displayName: Install rust (windows)
+ condition: eq( variables['Agent.OS'], 'Windows_NT' )
+
+ - script: |
+ rustc -Vv
+ cargo -V
+ displayName: Query rust and cargo versions