Resilience: LaunchAgent restarts BroV on crash; crashed Claude Code/Codex sessions get a resume button (optional auto); login and waiting status in the Claude/ChatGPT pills

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
maksarsanjeev
2026-10-06 22:56:39 +03:00
parent 37c01f991a
commit 0d40b78b26
9 changed files with 453 additions and 7 deletions
+9
View File
@@ -16,8 +16,17 @@ final class AppDelegate: NSObject, NSApplicationDelegate {
// Warm up Keychain cache on main thread BEFORE any poller or view touches it
_ = KeychainStore.shared
NSApp.setActivationPolicy(.accessory)
// One BroV at a time (launchd may start one while another is still quitting).
let me = ProcessInfo.processInfo.processIdentifier
if NSRunningApplication.runningApplications(withBundleIdentifier: Bundle.main.bundleIdentifier ?? "")
.contains(where: { $0.processIdentifier != me }) {
exit(0)
}
BroVLaunchAgent.ensure()
setupMenuBarItem()
CodexUsageMonitor.shared.start()
AgentWatch.shared.start()
AgentAuth.shared.start()
setupIsland()
#if PHONE_LINK
CloudProbe.shared.startIfEnabled()