Browse Source

fix: use eprintln to print errors

main
fdai7451 2 years ago
parent
commit
3ee0fbfea9
  1. 4
      src/main.rs

4
src/main.rs

@ -29,7 +29,7 @@ fn main() -> Result<()> {
break;
}
Err(ShellError::NotFound(cmd)) => {
println!("{}: command not found", cmd.get_program().to_string_lossy())
eprintln!("{}: command not found", cmd.get_program().to_string_lossy())
}
Err(ShellError::ExecuteFailure(msg)) => {
eprintln!("{}", msg)
@ -39,7 +39,7 @@ fn main() -> Result<()> {
break;
}
Err(err) => {
println!("Error: {:?}", err);
eprintln!("Error: {:?}", err);
break;
}
}

Loading…
Cancel
Save