Skip to content

Commit

Permalink
fix a bug in a fail state when using an invalid subcommand
Browse files Browse the repository at this point in the history
  • Loading branch information
ThomasLaPiana committed Oct 31, 2023
1 parent 1646d36 commit c0d7f5f
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,10 @@ pub fn rox() -> RoxResult<()> {
let task_name = args.subcommand_name().unwrap().to_owned();
vec![execute_tasks(vec![task_name], &task_map, false)]
}
&_ => std::process::abort(),
command => {
println!("'{}' is not a valid subcommand!", command);
std::process::exit(2);
}
};
output::display_execution_results(results.clone());
println!(
Expand Down

0 comments on commit c0d7f5f

Please sign in to comment.