terminal: Re-enable activation scripts on windows (#39604)

Release Notes:

- N/A *or* Added/Fixed/Improved ...
This commit is contained in:
Lukas Wirth
2025-10-06 15:07:15 +02:00
committed by GitHub
parent 2c1cc01b81
commit 93cd10aaa8

View File

@@ -616,10 +616,14 @@ impl TerminalBuilder {
child_exited: None,
};
if cfg!(not(target_os = "windows")) && !activation_script.is_empty() && no_task {
if !activation_script.is_empty() && no_task {
for activation_script in activation_script {
terminal.input(activation_script.into_bytes());
terminal.write_to_pty(b"\n");
terminal.write_to_pty(if cfg!(windows) {
b"\r\n" as &[_]
} else {
b"\n"
});
}
terminal.clear();
}