Fixing the error message for external commands
[?]
Dec 7, 2020, 7:59 AM
EZ7VRNRLL7L7I54BPYG4Y4PR7VRFAQXPVHCHDB3MQI3IYAQEKXEACDependencies
- [2]
SNZ3OAMCuse native external subcommand support instead of hand-rolled one - [3]
6GI4CC6JPrefix external subcommands with pijul- - [4]
SXEYMYF7Fixing the bad changes in history (unfortunately, by rebooting). - [5]
RJMQSZERExternal commands
Change contents
- replacement in pijul/src/main.rs at line 200
Err(std::process::Command::new(cmd).args(args).exec())writeln!(std::io::stderr(),"Error while running {:?}: {}",cmd,std::process::Command::new(&cmd).args(args).exec()).unwrap_or(());std::process::exit(1) - replacement in pijul/src/main.rs at line 216
let mut spawned = std::process::Command::new(cmd).args(args).spawn()?;let mut spawned = match std::process::Command::new(&cmd).args(args).spawn() {Ok(spawned) => spawned,Err(e) => {writeln!(std::io::stderr(), "Error while running {:?}: {}", cmd, e).unwrap_or(());std::process::exit(1)}};