Repository navigation
Releases
v0.4.4 — battery floor hysteresis
Upgrade
lich upgradeChanges
- Battery floor hysteresis. Once the floor ends roaming, it stays ended until the battery has charged 5 points past the floor: 25% by default, capped at 80% so Optimized Battery Charging can't block it. A few minutes on the charger, or a reading wobbling from 20% to 21%, no longer re-arms roaming only for the floor to end it again minutes later.
lich status, the arming messages and the log say when roaming will resume. lich installfrom a clone now asks for your password when the only missing piece is the/usr/local/bin/lichlink. Before, it only printed a warning.
v0.4.3 — idle-based timer, copy-safe install, Claude Code skill
Upgrade
lich upgradeWhat's new
- Claude Code skill (#2).
/plugin marketplace add JoJoAtkinson/lichbook, then/plugin install lichbook@lichbook. Or point Claude atskills/lichbook/SKILL.mdand it installs itself. Claude can then install lichbook, keep the Mac awake for long jobs, and hand it back withlich done. - Copy-safe install. The README install block is now one
&&chain with no inline comments. Stock zsh passes# commentsto the command as arguments, which brokebrew trustfor anyone withoutinteractivecommentsset. - Missing 💀 icon. The menu bar app now checks whether its icon is actually on screen. If it's hidden,
lich installtells you why: System Settings → Menu Bar → "Allow in the Menu Bar", a full menu bar behind the notch, or Bartender/Ice. - Idle-based roam timer.
lich roam timernow keeps the Mac awake on battery until nobody has touched it forroam_mins. Before, the countdown started at unplug. Any input re-arms it. lich install --no-appandlich config no_app 1now remove an installed menu bar app.
Fixes
- Logout reliably restores sleep. The watcher's SIGTERM trap used to restore sleep and then keep looping, which could turn sleep-disable back on before launchd killed it.
- Lid-close lock verification works. The
IOConsoleLockedprobe always read "not locked", because a pipe broke underpipefail. Every "lock did NOT take" warning before this release was false. - Watcher restarts, CLI calls and menu clicks no longer re-grant a fresh timer window.
- Plug and unplug are logged. Power assertions held 12h or more are flagged as probably stuck.
lich installapplies a changed watcher path immediately instead of at the next login.lich upgradefrom a clone no longer stops silently when the app build fails.
v0.4.2 — the battery note tells the truth
On battery with a standing timer whose window had already ended, lich status printed two lines that contradicted each other — and the wrong one was the reassuring one:
sleep: normal — lid-close sleeps
...
note: roaming — risen without the phylactery; 'lich done' when the work is finished
A lid closed on that note sleeps the Mac. The note was reading the roam mode (still timer, long after its grace window closed) instead of the live setting.
Now the note reads the same SleepDisabled the sleep: line does — so "normal — lid-close sleeps" and "roaming" can never appear together — and an ended window says so outright:
note: this unplug's grace window has ENDED — lid-close will sleep this Mac now
(fresh window on the next unplug, or: lich roam always)
Below the battery floor keeps precedence and is now worded "roaming is suspended until you charge past it" — off is a mode you chose, this is a pause.
Upgrade: lich upgrade (or brew update && brew upgrade lichbook && lich reload)
🤖 Generated with Claude Code
v0.4.1 — blockers name who started them
Small follow-up to v0.4.0's "held awake by:" listing: each blocker now names the process that started it, when that means something.
held awake by:
caffeinate — PreventUserIdleSystemSleep "caffeinate command-line tool" (held 00:00:42) — started by claude
Parent = launchd (Dock, Finder, login — i.e. launched normally) is omitted as noise, so normal apps stay clean and only the interesting ancestry shows.
Upgrade: lich upgrade (or brew update && brew upgrade lichbook && lich reload)
🤖 Generated with Claude Code
v0.4.0 — blocker visibility
Born from a real incident: lich handed sleep back on schedule, yet the Mac sat awake, screen on and unlocked, for two more hours — a Chrome tab's video wake lock vetoed every idle timer, and nothing said so.
Now lich names names:
lich statusgrows a "held awake by:" section listing every live power assertion — process, type, name, and how long it's been held (noise like powerd's derivative display-on assertion and 2-minute input tickles filtered out)- The watcher logs
blocker at handoff:lines the moment it hands sleep back to macOS on battery, so a Mac found awake hours later has its culprit on record - Overdue-sleep watchdog: still awake 15 minutes after a battery handoff → one warning per battery session naming the holders
- Lid-close lock diagnostics: the "lock did NOT take" warning now reports ScreenSaverEngine state, the actual screenLock delay setting, and IOConsoleLocked — evidence, not guesses
Walk-away confidence: on battery, lich status (and the menu bar, automatically) now shows exactly when the roam window ends:
sleep: disabled — hands back to macOS at 09:38 (30 min left)
Upgrade: lich upgrade (or brew update && brew upgrade lichbook && lich reload)
🤖 Generated with Claude Code
v0.3.4 — field-proven on two machines
lichbook keeps a MacBook awake with the lid closed — but only while it is plugged in. Unplug it, log out, or turn it off, and it sleeps like any mortal machine.
Install
brew tap jojoatkinson/lichbook https://github.com/JoJoAtkinson/lichbook
brew trust jojoatkinson/lichbook
brew install lichbook
lich install
lich onHighlights at v0.3.4
- CLI + menu bar skull (💀/⚰️) + optional Control Center toggle — the menu bar app is built on your machine during
brew install(ad-hoc signing, no downloads to trust) - Roaming: stay awake on battery — one trip, a timed window, or a standing setting — always under a hard battery floor (default 20%)
- For AI agents:
lich donehands the machine back when the work is finished - Fail-open install with per-user sudoers scoped to exactly two
pmsetcommands; works for non-admins once an admin grants the rule lich upgrade— one word updates everything (brew or clone)- Every state change logged; formal behavior reference in docs/STATE-TABLE.md, with the core paths field-tested and cited
Tested on macOS 26 (Tahoe), Apple Silicon. Earlier versions: fail-open, loosely supported, no promises.