:: Copyright 2022 The Chromium OS Authors. All rights reserved. :: Use of this source code is governed by a BSD-style license that can be :: found in the LICENSE file. :: Make environment changes (cd, env vars, etc.) local, so they don't affect the calling batch file setlocal :: Code under repo is checked out to %KOKORO_ARTIFACTS_DIR%\git. :: The final directory name in this path is determined by the scm name specified :: in the job configuration cd %KOKORO_ARTIFACTS_DIR%\git\crosvm :: Pin rustup to a known/tested version. set rustup_version=1.24.3 :: Install rust toolchain through rustup. echo [%TIME%] installing rustup %rustup_version% choco install -y rustup.install --version=%rustup_version% :: Reload path for installed rustup binary call RefreshEnv.cmd set /p rust_version=