aboutsummaryrefslogtreecommitdiffstats
path: root/crates/turtle/src/atuin_daemon/components/search.rs
diff options
context:
space:
mode:
authorBenedikt Peetz <benedikt.peetz@b-peetz.de>2026-06-11 14:20:49 +0200
committerBenedikt Peetz <benedikt.peetz@b-peetz.de>2026-06-11 14:20:49 +0200
commit199563550dd41c3dfb703bd3747604a8a03cdbc5 (patch)
tree30cfa3e5539f782b7571091c742ee1c219e138fb /crates/turtle/src/atuin_daemon/components/search.rs
parentchore: Restore db migrations (diff)
downloadatuin-199563550dd41c3dfb703bd3747604a8a03cdbc5.zip
chore: Remove all `pub`s
They will not be marked by rustc/cargo as unused, and as atuin doesn't expose an API all of them _should_ be `pub(crate)`
Diffstat (limited to 'crates/turtle/src/atuin_daemon/components/search.rs')
-rw-r--r--crates/turtle/src/atuin_daemon/components/search.rs12
1 files changed, 6 insertions, 6 deletions
diff --git a/crates/turtle/src/atuin_daemon/components/search.rs b/crates/turtle/src/atuin_daemon/components/search.rs
index 85191cff..17decdad 100644
--- a/crates/turtle/src/atuin_daemon/components/search.rs
+++ b/crates/turtle/src/atuin_daemon/components/search.rs
@@ -34,7 +34,7 @@ const FRECENCY_REFRESH_INTERVAL_SECS: u64 = 60;
/// - Loads history from the database on startup
/// - Updates the index when history events occur
/// - Provides the Search gRPC service
-pub struct SearchComponent {
+pub(crate) struct SearchComponent {
index: Arc<RwLock<SearchIndex>>,
handle: tokio::sync::RwLock<Option<DaemonHandle>>,
loader_handle: Option<tokio::task::JoinHandle<()>>,
@@ -43,7 +43,7 @@ pub struct SearchComponent {
impl SearchComponent {
/// Create a new search component.
- pub fn new() -> Self {
+ pub(crate) fn new() -> Self {
Self {
index: Arc::new(RwLock::new(SearchIndex::new())),
handle: tokio::sync::RwLock::new(None),
@@ -53,7 +53,7 @@ impl SearchComponent {
}
/// Get the gRPC service for this component.
- pub fn grpc_service(&self) -> SearchServer<SearchGrpcService> {
+ pub(crate) fn grpc_service(&self) -> SearchServer<SearchGrpcService> {
SearchServer::new(SearchGrpcService {
index: self.index.clone(),
})
@@ -273,7 +273,7 @@ impl Component for SearchComponent {
}
/// The gRPC service implementation.
-pub struct SearchGrpcService {
+pub(crate) struct SearchGrpcService {
index: Arc<RwLock<SearchIndex>>,
}
@@ -395,7 +395,7 @@ fn convert_filter_mode(
}
#[cfg(windows)]
-pub fn with_trailing_slash(s: &str) -> String {
+pub(crate) fn with_trailing_slash(s: &str) -> String {
if s.ends_with('\\') {
s.to_string()
} else {
@@ -404,7 +404,7 @@ pub fn with_trailing_slash(s: &str) -> String {
}
#[cfg(not(windows))]
-pub fn with_trailing_slash(s: &str) -> String {
+pub(crate) fn with_trailing_slash(s: &str) -> String {
if s.ends_with('/') {
s.to_string()
} else {