Skip to content

Commit 77e03e0

Browse files
author
Steve Lee (POWERSHELL HE/HIM) (from Dev Box)
committed
don't run msrustup at all within ADO
1 parent 0292085 commit 77e03e0

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

build.ps1

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -155,16 +155,17 @@ function Find-LinkExe {
155155
}
156156

157157
$channel = 'stable'
158-
if ($null -ne (Get-Command msrustup -CommandType Application -ErrorAction Ignore)) {
158+
$rustup = 'echo'
159+
if ($usingADO) {
160+
break
161+
} elseif ($null -ne (Get-Command msrustup -CommandType Application -ErrorAction Ignore)) {
159162
$rustup = 'msrustup'
160163
$channel = 'ms-stable'
161164
if ($architecture -eq 'current') {
162165
$env:MSRUSTUP_TOOLCHAIN = "$architecture"
163166
}
164167
} elseif ($null -ne (Get-Command rustup -CommandType Application -ErrorAction Ignore)) {
165168
$rustup = 'rustup'
166-
} else {
167-
$rustup = 'echo'
168169
}
169170

170171
if ($null -ne $packageType) {
@@ -185,7 +186,7 @@ if ($null -ne $packageType) {
185186
Remove-Item temp:/rustup-init.exe -ErrorAction Ignore
186187
}
187188
}
188-
elseif (!$usingADO) {
189+
else {
189190
Write-Verbose -Verbose "Rust found, updating..."
190191
& $rustup update
191192
}

0 commit comments

Comments
 (0)