insomnia

Insomnia

Caffeinate for the agentic era.

01 the menu bar

One eye in your menu bar.

It keeps your Mac awake until a time you pick.

Click the eye.

Days, hours and minutes slide out.

Type 8, press Enter.

Awake until the countdown reaches zero.

Click the countdown.

Type more time and it adds on.

Hold × to end.

A 0.6 second hold, so a stray click can't.

Right-click the eye.

Status first, then Settings and Quit.

scroll to play it, or use the pill yourself

02

Lid closed.
Still running.

Your agents keep working with the lid closed. Opening it tries to undo everything in this log.

Built-in mics cut out with the lid closed. Use AirPods or an external mic.

insomnia.logduring a session
  1. lid closed
  2. display, keyboard lightoffbrightness saved
  3. slack, whatsapp, discordfrozenSIGSTOP
  4. audiomuted
  5. low power modeon
  6. docker desktopfrozenopt-in, no containers
  7. claude code, codexrunning
  8. timer7:59:56still counting
  9. lid opened
  10. display, keyboard lightrestored
  11. frozen appsresumedSIGCONT
  12. audiounmuted
  13. low power modeoffunless a rule needs it

03

Battery and heat.

These are the defaults. Change them in Settings.

The rules only run while the app is open.

batterydefaults
  1. 100%[##############################]awake
  2. 40%[############··················]Low Power Mode on
  3. 10%[###···························]session ends
  4. heatserious: Low Power Mode on · critical: session ends

04

Recovery.

Every change goes into a journal on disk before it happens, so it can be undone even after a crash.

If the menu shows a recovery warning, fix it before you leave the Mac alone.

recovery journalevery change
  1. 1write the change to the journal
  2. 2make the change
  3. 3session endsundo what the journal lists
  4. ?app crashed or quitthe launchd agent undoes it after the end time
  5. !an undo failedthe entry stays on disk and the menu warns you

05

Optional extras.

hotspotoff until set up

Joins your iPhone's hotspot if the Wi‑Fi drops.

tmuxmarked panes only

Types continue into a marked agent pane after 90 s offline.

browsersasks first

Offers to relaunch Chrome, Chromium and Arc so hidden windows run at full speed.

06

Install.

macOS 26 or later, Apple silicon. Paste this into your coding agent:

prompt
Install the latest stable Insomnia release by following https://github.com/krishhgg/Insomnia/blob/main/skills/install-insomnia/SKILL.md. If a step needs my password, give me the command to run in Terminal.

Or follow docs/install.md. It adds a sudoers rule, so read what it installs first.

Insomnia is experimental. Recovery can fail, and a timer is not a safety guarantee. Keep the Mac on a stable, ventilated surface, never in a closed bag. Validation status

h top m menu bar l lid b battery r recovery i install

asleep