summaryrefslogtreecommitdiffstats
path: root/atuin-server-database
diff options
context:
space:
mode:
authorEllie Huxtable <ellie@elliehuxtable.com>2023-07-14 20:44:47 +0100
committerGitHub <noreply@github.com>2023-07-14 20:44:47 +0100
commit578615596975b5a2e6aa8b8d7a8f36b9e390f9ea (patch)
tree3898fe4b1b987ade80a3a8fb175bb09817bd7c5c /atuin-server-database
parent97e24d0d41bb743833e457de5ba49c5c233eb3b3 (diff)
Add total history count to the index API (#1102)
Thought it would be fun to collect some cool stats, maybe put them on atuin.sh.
Diffstat (limited to 'atuin-server-database')
-rw-r--r--atuin-server-database/src/lib.rs1
1 files changed, 1 insertions, 0 deletions
diff --git a/atuin-server-database/src/lib.rs b/atuin-server-database/src/lib.rs
index cdff90a2a..06ecf910d 100644
--- a/atuin-server-database/src/lib.rs
+++ b/atuin-server-database/src/lib.rs
@@ -52,6 +52,7 @@ pub trait Database: Sized + Clone + Send + Sync + 'static {
async fn add_user(&self, user: &NewUser) -> DbResult<i64>;
async fn delete_user(&self, u: &User) -> DbResult<()>;
+ async fn total_history(&self) -> DbResult<i64>;
async fn count_history(&self, user: &User) -> DbResult<i64>;
async fn count_history_cached(&self, user: &User) -> DbResult<i64>;