summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorJesse Luehrs <doy@tozt.net>2021-11-10 13:34:55 -0500
committerJesse Luehrs <doy@tozt.net>2021-11-10 13:34:55 -0500
commita94d4381453c0ae3bed63524b1a1451413159772 (patch)
tree15d77621d88573708754727cae7e5dc68d1d5e95 /src
parent0d0380af5a90503e30ae6678c54d481eb81ceec1 (diff)
downloadnbsh-a94d4381453c0ae3bed63524b1a1451413159772.tar.gz
nbsh-a94d4381453c0ae3bed63524b1a1451413159772.zip
fix display of long running commands with no output
Diffstat (limited to 'src')
-rw-r--r--src/history.rs4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/history.rs b/src/history.rs
index bf46693..128535b 100644
--- a/src/history.rs
+++ b/src/history.rs
@@ -116,6 +116,10 @@ impl History {
if used_lines > 24 {
break;
}
+ if used_lines == 1 {
+ used_lines = 2;
+ pos = Some((23, 0));
+ }
out.move_to((24 - used_lines).try_into().unwrap(), 0);
out.write_str("$ ");
if entry.running {