Skip to content

Commit

Permalink
feat: Better default error info
Browse files Browse the repository at this point in the history
  • Loading branch information
mcmah309 committed Dec 14, 2024
1 parent 4cdde38 commit 3fa8a99
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -41,10 +41,11 @@ async fn main() {
Commands::Update { path } => update(&path),
};
if let Err(error) = result {
eprintln!("Oops something went wrong.\n");
eprintln!("{:?}", error);
if is_debug {
eprintln!("{:?}", error);
} else {
eprintln!("Oops something went wrong.");
eprintln!(
"For more info, try again with environment variable `CONTAINERYARD_DEBUG` set to anything but `0`."
);
Expand Down

0 comments on commit 3fa8a99

Please sign in to comment.