summaryrefslogtreecommitdiff
path: root/cli/lib.rs
diff options
context:
space:
mode:
authorBartek IwaƄczuk <biwanczuk@gmail.com>2020-05-09 21:09:46 +0200
committerGitHub <noreply@github.com>2020-05-09 21:09:46 +0200
commit1fddcc372196466799789350e7950cef1a38d35e (patch)
treef8e3d43170e2208a9f3f8bf1f12edbb3ed6b1d2e /cli/lib.rs
parent670d01d0126d80c0acfd22a76148dcbd831763cb (diff)
refactor(cli): unify display of errors from Rust and JS (#5183)
Diffstat (limited to 'cli/lib.rs')
-rw-r--r--cli/lib.rs7
1 files changed, 6 insertions, 1 deletions
diff --git a/cli/lib.rs b/cli/lib.rs
index 957637719..97b497e95 100644
--- a/cli/lib.rs
+++ b/cli/lib.rs
@@ -626,7 +626,12 @@ pub fn main() {
let result = tokio_util::run_basic(fut);
if let Err(err) = result {
- eprintln!("{}", err.to_string());
+ let msg = format!(
+ "{}: {}",
+ colors::red_bold("error".to_string()),
+ err.to_string(),
+ );
+ eprintln!("{}", msg);
std::process::exit(1);
}
}