aboutsummaryrefslogtreecommitdiffstats
path: root/crates/client/src/command/client.rs
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--crates/client/src/command/client.rs28
1 files changed, 16 insertions, 12 deletions
diff --git a/crates/client/src/command/client.rs b/crates/client/src/command/client.rs
index 42e72e21..9f45f53b 100644
--- a/crates/client/src/command/client.rs
+++ b/crates/client/src/command/client.rs
@@ -37,11 +37,12 @@ fn cleanup_old_logs(log_dir: &Path, prefix: &str, retention_days: u64) {
}
mod config;
+mod daemon;
mod default_config;
mod history;
mod info;
mod stats;
-mod store;
+// mod store;
mod sync;
mod wrapped;
@@ -52,14 +53,17 @@ pub(crate) enum Cmd {
#[command(subcommand)]
History(history::Cmd),
+ /// Interact with the daemon
#[command(subcommand)]
- /// Request a sync or view sync status
- Sync(sync::Cmd),
+ Daemon(daemon::Cmd),
- /// Manage the atuin data store
#[command(subcommand)]
- Store(store::Cmd),
+ /// Request a sync or view sync status
+ Sync(sync::Cmd),
+ // /// Manage the atuin data store
+ // #[command(subcommand)]
+ // Store(store::Cmd),
/// Information about dotfiles locations and ENV vars
#[command()]
Info,
@@ -97,7 +101,7 @@ impl Cmd {
res
}
- async fn run_inner(self, mut settings: Settings) -> Result<()> {
+ async fn run_inner(self, settings: Settings) -> Result<()> {
// ATUIN_LOG env var overrides config file level settings
let env_log_set = std::env::var("ATUIN_LOG").is_ok();
@@ -117,14 +121,14 @@ impl Cmd {
}
match self {
- Self::Stats(stats) => stats.run(&db, &settings).await,
- Self::Wrapped { year } => wrapped::run(year, &db, &settings).await,
-
- Self::Sync(sync) => sync.run(settings, &db, sqlite_store).await,
+ Self::Daemon(cmd) => cmd.run(&settings).await,
+ Self::Sync(sync) => sync.run(settings).await,
- Self::Store(store) => store.run(&settings, &db, sqlite_store).await,
+ Self::Stats(stats) => stats.run(&settings).await,
+ Self::Wrapped { year } => wrapped::run(year, &settings).await,
- Self::Info => info::run(&settings),
+ // Self::Store(store) => store.run(&settings, &db, sqlite_store).await,
+ Self::Info => info::run(&settings).await,
Self::DefaultConfig => {
default_config::run();