summaryrefslogtreecommitdiffstats
path: root/src/history.rs
diff options
context:
space:
mode:
authorJesse Luehrs <doy@tozt.net>2021-11-13 16:33:32 -0500
committerJesse Luehrs <doy@tozt.net>2021-11-13 16:33:32 -0500
commit57ee8da77b3f8a0a265544b9f2cb6fbb247ccc3b (patch)
tree1193dad97f7d62f9f181dc75f61cbc44fcbcd75a /src/history.rs
parentb7a0201d42995e34df4f541b23826ff7ac42dd9f (diff)
downloadnbsh-57ee8da77b3f8a0a265544b9f2cb6fbb247ccc3b.tar.gz
nbsh-57ee8da77b3f8a0a265544b9f2cb6fbb247ccc3b.zip
allow moving focus between history entries
Diffstat (limited to 'src/history.rs')
-rw-r--r--src/history.rs4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/history.rs b/src/history.rs
index 5397c68..048cc1e 100644
--- a/src/history.rs
+++ b/src/history.rs
@@ -194,6 +194,10 @@ impl History {
}
}
}
+
+ pub fn entry_count(&self) -> usize {
+ self.entries.len()
+ }
}
struct HistoryEntry {