From 8a1f493a8454ccc93e371ca62073d72fc7ae56b6 Mon Sep 17 00:00:00 2001 From: Yethal <26117918+Yethal@users.noreply.github.com> Date: Fri, 7 Mar 2025 09:36:27 +0100 Subject: [PATCH 1/2] Correct Nushell source command --- rustup-init.sh | 2 +- src/cli/self_update.rs | 6 +++--- src/cli/self_update/shell.rs | 3 ++- 3 files changed, 6 insertions(+), 5 deletions(-) diff --git a/rustup-init.sh b/rustup-init.sh index a48afd171b..52f2b9e1f5 100755 --- a/rustup-init.sh +++ b/rustup-init.sh @@ -33,7 +33,7 @@ RUSTUP_QUIET=no # NOTICE: If you change anything here, please make the same changes in setup_mode.rs usage() { cat < Result { - Ok(format!(r#"source "{}/env.nu""#, cargo_home_str(process)?)) + let cargo_home_nushell = (cargo_home_str(process)?).replace("$HOME", "($nu.home-path)"); + Ok(format!(r#"source $"{}/env.nu""#, cargo_home_nushell)) } } From a4e468e2ceb993590dda12287ef32ac25478b095 Mon Sep 17 00:00:00 2001 From: Yethal <26117918+Yethal@users.noreply.github.com> Date: Fri, 7 Mar 2025 10:06:23 +0100 Subject: [PATCH 2/2] Correct Nushell source command --- rustup-init.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/rustup-init.sh b/rustup-init.sh index 52f2b9e1f5..a48afd171b 100755 --- a/rustup-init.sh +++ b/rustup-init.sh @@ -33,7 +33,7 @@ RUSTUP_QUIET=no # NOTICE: If you change anything here, please make the same changes in setup_mode.rs usage() { cat <