Skip to content

Your home as a live 3D model in the Mac menu bar and on iPhone — lights and ACs via Smart Life, Home Assistant, Philips Hue and Apple Home.

580 B
Raw Blame
import AppKit
import HouseCore
import HouseSmartLife

MainActor.assumeIsolated {
    // `--selftest-mapper`, `--selftest-infrared`, `--selftest-transport` and
    // `--diagnose <id>…` print their result and exit without starting the app.
    SelfTest.runIfRequested()

    let app = NSApplication.shared
    let delegate = AppDelegate()
    app.delegate = delegate
    // Menu bar only: no Dock icon (HOUSE_DOCK=1 shows one, handy for UI automation).
    app.setActivationPolicy(ProcessInfo.processInfo.environment["HOUSE_DOCK"] != nil ? .regular : .accessory)
    app.run()
}