From 19528ba8babe2e2ea5100bd50682dfd601b9d09b Mon Sep 17 00:00:00 2001 From: spiders Date: Sat, 28 May 2022 13:50:13 -0700 Subject: [PATCH] errors get printed to standard error now --- src/lib.rs | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/lib.rs b/src/lib.rs index 2e62a04..d95ce11 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -27,9 +27,9 @@ pub fn run(mode: Modes) { match cli.configs_from_arguments() { Err((s, e)) => { if cli.inli { - println!("error:\n{}", e); + eprintln!("error:\n{}", e); } else { - println!("pakala a!\n{}", s); + eprintln!("pakala a!\n{}", s); } return; } @@ -41,9 +41,9 @@ pub fn run(mode: Modes) { match critters::list_files() { Err((s, e)) => { if cli.inli { - println!("error: {}", e) + eprintln!("error: {}", e) } else { - println!("pakala a!\n{}", s) + eprintln!("pakala a!\n{}", s) } } Ok(files) => { @@ -56,7 +56,7 @@ pub fn run(mode: Modes) { } else { io::stdin() .read_to_string(&mut text) - .expect("failed to read input"); + .expect("mi ken ala lukin e pana sina."); } output(&text, critter_config, bubble_config); }