summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorandy.boot <bootandy@gmail.com>2023-01-22 10:18:21 +0000
committerandy.boot <bootandy@gmail.com>2023-01-29 09:52:10 +0000
commit1e87a0661bb2e94734e7228ce1d63c353641499b (patch)
tree9550ee5b2dd24522e10ade24806e89d5b5df7788
parent187b8be2fa0baccc9f1455e195f8d5ba492a9e80 (diff)
fix: Fix bug in progress bar
Must entirely clear screen before printing output
-rw-r--r--src/progress.rs1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/progress.rs b/src/progress.rs
index d0e0f0f..15f7722 100644
--- a/src/progress.rs
+++ b/src/progress.rs
@@ -129,6 +129,7 @@ impl PIndicator {
progress_char_i += 1;
progress_char_i %= PROGRESS_CHARS_LEN;
}
+ print!("\r{:width$}", " ", width = msg.len());
print!("\r");
stdout.flush().unwrap();
});