From be6881e28fdd6cc9152c6cfe53feecdb641b0365 Mon Sep 17 00:00:00 2001 From: tsukimizake Date: Sun, 15 Dec 2024 17:44:37 +0900 Subject: [PATCH] stop the prompt from removing the last newline --- crates/nu-cli/src/prompt_update.rs | 8 -------- 1 file changed, 8 deletions(-) diff --git a/crates/nu-cli/src/prompt_update.rs b/crates/nu-cli/src/prompt_update.rs index c033475586..661b8c65f7 100644 --- a/crates/nu-cli/src/prompt_update.rs +++ b/crates/nu-cli/src/prompt_update.rs @@ -87,14 +87,6 @@ fn get_prompt_string( x.insert_str(0, "\x1b[0m") }; - // Just remove the very last newline. - if x.ends_with('\n') { - x.pop(); - } - - if x.ends_with('\r') { - x.pop(); - } x }); // Let's keep this for debugging purposes with nu --log-level warn