fix: broken rules for new nushell version

This commit is contained in:
iff 2024-11-18 13:38:21 +01:00
parent 8f9aac6bdc
commit a71486e956
3 changed files with 8 additions and 3 deletions

View file

@ -249,9 +249,11 @@ end
pub fn shell_syntax(shell: &str, command: &mut String) {
#[allow(clippy::single_match)]
eprintln!("command: {}", command);
match shell {
"nushell" => {
"nu" => {
*command = command.replace(" && ", " and ");
eprintln!("command: {}", command);
}
_ => {}
}
@ -276,7 +278,7 @@ pub fn shell_evaluated_commands(shell: &str, command: &str) -> Option<String> {
#[allow(clippy::single_match)]
match shell {
"nushell" => Some(cd_dir),
"nu" => Some(cd_dir),
_ => Some(format!("cd {}", cd_dir)),
}
}