summaryrefslogtreecommitdiff
path: root/cli/util/file_watcher.rs
diff options
context:
space:
mode:
Diffstat (limited to 'cli/util/file_watcher.rs')
-rw-r--r--cli/util/file_watcher.rs3
1 files changed, 2 insertions, 1 deletions
diff --git a/cli/util/file_watcher.rs b/cli/util/file_watcher.rs
index ddeedb741..c0eda2d86 100644
--- a/cli/util/file_watcher.rs
+++ b/cli/util/file_watcher.rs
@@ -16,6 +16,7 @@ use notify::RecommendedWatcher;
use notify::RecursiveMode;
use notify::Watcher;
use std::collections::HashSet;
+use std::io::IsTerminal;
use std::path::PathBuf;
use std::sync::Arc;
use std::time::Duration;
@@ -98,7 +99,7 @@ pub struct PrintConfig {
fn create_print_after_restart_fn(clear_screen: bool) -> impl Fn() {
move || {
- if clear_screen && atty::is(atty::Stream::Stderr) {
+ if clear_screen && std::io::stderr().is_terminal() {
eprint!("{CLEAR_SCREEN}");
}
info!(