File tree Expand file tree Collapse file tree 1 file changed +12
-11
lines changed Expand file tree Collapse file tree 1 file changed +12
-11
lines changed Original file line number Diff line number Diff line change @@ -15,20 +15,21 @@ steps:
1515 displayName: Install rust (unix)
1616 condition: ne( variables['Agent.OS'], 'Windows_NT' )
1717
18- - powershell : |
19- if (!$env:TOOLCHAIN) {
20- $env:TOOLCHAIN = "stable-${env:TARGET}";
21- }
22- if ($env:RUSTUP_HOME) {
23- rustup update --no-self-update $env:TOOLCHAIN
24- rustup default $env:TOOLCHAIN
25- } else {
18+ - bash : |
19+ set -e
20+ toolchain=$TOOLCHAIN
21+ if [ "$toolchain" = "" ]; then
22+ toolchain=stable-$TARGET
23+ fi
24+ if command -v rustup; then
25+ rustup update $toolchain
26+ rustup default $toolchain
27+ else
2628 curl.exe -sSf -o rustup-init.exe https://win.rustup.rs
2729 ./rustup-init.exe -y --default-toolchain $env:TOOLCHAIN
28- Write-Host "##vso[task.prependpath]${env: USERPROFILE} /.cargo/bin"
29- }
30+ echo "##vso[task.prependpath]$USERPROFILE/.cargo/bin"
31+ fi
3032 displayName: Install rust (windows)
31- failOnStderr: false
3233 condition: eq( variables['Agent.OS'], 'Windows_NT' )
3334
3435 - script : |
You can’t perform that action at this time.
0 commit comments