Update task error message

This commit is contained in:
Dheepak Krishnamurthy 2020-10-29 11:50:05 -06:00
parent e12d398508
commit cb6cca0646

View file

@ -43,10 +43,17 @@ fn main() -> Result<(), Box<dyn Error>> {
match r {
Ok(_) => std::process::exit(0),
Err(error) => {
if error.to_string().to_lowercase().contains("no such file or directory") {
eprintln!(
"{}: Unable to find executable `task`: {}. Check that taskwarrior is install correctly and try again.",
"[taskwarrior-tui error]", error
);
} else {
eprintln!(
"{}: {}. Please report as a github issue on https://github.com/kdheepak/taskwarrior-tui",
"[taskwarrior-tui error]", error
);
}
std::process::exit(1);
}
}