Skip to content

Commit 16db0cb

Browse files
committed
[Devsetup] Install the latest rust toolchain
1 parent 49d6406 commit 16db0cb

File tree

1 file changed

+7
-6
lines changed

1 file changed

+7
-6
lines changed

scripts/dev_setup.sh

+7-6
Original file line numberDiff line numberDiff line change
@@ -461,13 +461,9 @@ function install_toolchain {
461461
}
462462

463463
function install_rustup_components_and_nightly {
464-
echo "Printing the rustup version and toolchain list"
465-
rustup --version
466-
rustup show
467-
rustup toolchain list -v
468-
469-
echo "Updating rustup and installing rustfmt & clippy"
464+
echo "Updating rustup and installing the latest rustc, rustfmt & clippy"
470465
rustup update
466+
rustup toolchain install stable # Install the latest toolchain to ensure that dependencies can always be built (even if aptos-core is behind)
471467
rustup component add rustfmt
472468
rustup component add clippy
473469

@@ -490,6 +486,11 @@ function install_rustup_components_and_nightly {
490486
if ! rustup component add rustfmt --toolchain nightly; then
491487
echo "Failed to install rustfmt nightly using rustup."
492488
fi
489+
490+
echo "Printing the rustup version and toolchain list"
491+
rustup --version
492+
rustup show
493+
rustup toolchain list -v
493494
}
494495

495496
function install_cargo_sort {

0 commit comments

Comments
 (0)