diff options
| author | Benedikt Peetz <benedikt.peetz@b-peetz.de> | 2026-07-20 23:00:06 +0200 |
|---|---|---|
| committer | Benedikt Peetz <benedikt.peetz@b-peetz.de> | 2026-07-20 23:00:06 +0200 |
| commit | 2f671f196e245ac1a791c001286e401a2fab9d3a (patch) | |
| tree | be90d8f16d5c8b65c6b77ebe1359d22e9738bbf6 /crates/daemon/src/aclient/history/mod.rs | |
| parent | chore: Commit (diff) | |
| download | atuin-2f671f196e245ac1a791c001286e401a2fab9d3a.zip | |
chore: Commit
Diffstat (limited to 'crates/daemon/src/aclient/history/mod.rs')
| -rw-r--r-- | crates/daemon/src/aclient/history/mod.rs | 16 |
1 files changed, 6 insertions, 10 deletions
diff --git a/crates/daemon/src/aclient/history/mod.rs b/crates/daemon/src/aclient/history/mod.rs index ea71dcf4..f9afa5e9 100644 --- a/crates/daemon/src/aclient/history/mod.rs +++ b/crates/daemon/src/aclient/history/mod.rs @@ -1,14 +1,10 @@ -use core::fmt::Formatter; use regex::RegexSet; use rmp::decode::DecodeStringError; use rmp::decode::ValueReadError; use rmp::{Marker, decode::Bytes}; -use std::env; -use std::fmt::Display; use turtle::history::History; use turtle_common::record::DecryptedData; -use turtle_common::utils::uuid_v7; use eyre::{Result, bail, eyre}; @@ -16,12 +12,12 @@ use time::OffsetDateTime; pub(crate) mod store; -pub(crate) const HISTORY_VERSION_V0: &str = "v0"; -pub(crate) const HISTORY_VERSION_V1: &str = "v1"; +const HISTORY_VERSION_V0: &str = "v0"; +const HISTORY_VERSION_V1: &str = "v1"; const HISTORY_RECORD_VERSION_V0: u16 = 0; const HISTORY_RECORD_VERSION_V1: u16 = 1; -pub(crate) const HISTORY_VERSION: &str = HISTORY_VERSION_V1; -pub(crate) const HISTORY_TAG: &str = "history"; +const HISTORY_VERSION: &str = HISTORY_VERSION_V1; +const HISTORY_TAG: &str = "history"; const HISTORY_AUTHOR_ENV: &str = "ATUIN_HISTORY_AUTHOR"; const HISTORY_INTENT_ENV: &str = "ATUIN_HISTORY_INTENT"; @@ -45,7 +41,7 @@ pub(crate) struct HistoryStats { pub(crate) duration_over_time: Vec<(String, i64)>, } -pub(crate) trait HistoryExt: Sized { +trait HistoryExt: Sized { fn serialize(&self) -> Result<DecryptedData>; fn read_optional_string(bytes: &[u8]) -> Result<(Option<String>, &[u8])>; fn deserialize_v0(bytes: &[u8]) -> Result<Self>; @@ -260,7 +256,7 @@ impl HistoryExt for History { } #[derive(Debug, Copy, Clone)] -pub struct SettingsFilter<'a> { +struct SettingsFilter<'a> { pub history: &'a RegexSet, pub cwd: &'a RegexSet, pub secrets: bool, |
