diff --git a/install.bash b/install.bash index 9acef56..6ecf0e6 100644 --- a/install.bash +++ b/install.bash @@ -102,7 +102,13 @@ install-rust() { fi export PATH="${PATH}:${install_path}/cargo/bin" - rustup default stable + if [[ -z "$(ls "${RUSTUP_HOME}/toolchains")" ]]; then + log "info" "No toolchain found, installing a ${GREEN}Rust${RESET_BOLD} toolchain" + log "info" "Setting ${GREEN}Rust{$RESET_BOLD}'s toolchain to ${GREEN}stable${RESET_BOLD}" + rustup default stable + else + log "info" "${GREEN}Rust${RESET_BOLD} toolchain found, skipping toolchain setup" + fi } install-cargo-binary() {