aboutsummaryrefslogtreecommitdiffstats
path: root/src/bin/rbw-agent/main.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/bin/rbw-agent/main.rs')
-rw-r--r--src/bin/rbw-agent/main.rs12
1 files changed, 10 insertions, 2 deletions
diff --git a/src/bin/rbw-agent/main.rs b/src/bin/rbw-agent/main.rs
index f5d478d..d470e10 100644
--- a/src/bin/rbw-agent/main.rs
+++ b/src/bin/rbw-agent/main.rs
@@ -10,6 +10,10 @@
#![allow(clippy::too_many_arguments)]
#![allow(clippy::too_many_lines)]
#![allow(clippy::type_complexity)]
+#![allow(clippy::multiple_crate_versions)]
+#![allow(clippy::large_enum_variant)]
+// this one looks plausibly useful, but currently has too many bugs
+#![allow(clippy::significant_drop_tightening)]
use anyhow::Context as _;
@@ -17,7 +21,9 @@ mod actions;
mod agent;
mod daemon;
mod debugger;
+mod notifications;
mod sock;
+mod timeout;
async fn tokio_main(
startup_ack: Option<crate::daemon::StartupAck>,
@@ -28,7 +34,7 @@ async fn tokio_main(
startup_ack.ack()?;
}
- let mut agent = crate::agent::Agent::new()?;
+ let agent = crate::agent::Agent::new()?;
agent.run(listener).await?;
Ok(())
@@ -44,6 +50,8 @@ fn real_main() -> anyhow::Result<()> {
.nth(1)
.map_or(false, |arg| arg == "--no-daemonize");
+ rbw::dirs::make_all()?;
+
let startup_ack = if no_daemonize {
None
} else {
@@ -78,7 +86,7 @@ fn main() {
if let Err(e) = res {
// XXX log file?
- eprintln!("{:#}", e);
+ eprintln!("{e:#}");
std::process::exit(1);
}
}