Monitor ADB device presence and withdraw stale registrations in 0.2.6

This commit is contained in:
tongtong committed 2026-11-13 21:55:45 +08:00
1 parent 03e729a60b
commit dc29a20a41
17 files changed
+488 -23

No files matched your search

+6
View File
@@ -1,3 +1,4 @@
mod adb_monitor;
mod gateway;
mod managed;
mod supervisor;
@@ -69,7 +70,12 @@ async fn main() -> Result<()> {
bail!("valid device and exactly one of --target / --adb-serial are required")
}
args.network.url("/v1/agent", &[])?;
let monitor = args
.adb_serial
.as_ref()
.map(|_| adb_monitor::Monitor::start(args.adb_server.clone()));
let worker = gateway::Gateway {
adb_presence: monitor.as_ref().map(|m| m.receiver.clone()),
network: args.network,
token,
device,