fuji-mak/Capsomnia
A tiny macOS app that turns Caps Lock into a physical keep-awake switch for closed-lid MacBook work.
What it solves
Capsomnia prevents MacBooks from sleeping when the lid is closed, solving the problem where standard sleep-prevention tools (like caffeinate) often fail to keep local processes running during closed-lid use. This is particularly useful for maintaining the operation of AI agents, long-running scripts, and remote SSH sessions without needing to keep the laptop open.
How it works
The app turns the physical Caps Lock key into a hardware toggle for sleep prevention. When Caps Lock is on (indicated by the green LED), the app uses a privileged native helper to disable system sleep. When Caps Lock is off, normal sleep behavior is restored. It can also optionally prevent the Caps Lock key from actually typing in all-caps and can keep the display session active for remote UI tools.
Who it’s for
Developers and power users who run AI coding agents, unattended scripts, or remote workloads on MacBooks and want a physical, visible indicator of whether their machine will stay awake with the lid closed.
Highlights
- Physical Toggle: Uses the Caps Lock LED as a clear visual indicator of the awake state.
- Closed-Lid Support: Specifically designed to keep local jobs running even when the lid is shut.
- Auto-off Timer: Optional timers (from 1 minute to 24 hours) that automatically restore sleep behavior and can trigger immediate sleep if the lid is closed.
- Remote UI Compatibility: An optional "Keep display awake" mode that allows remote UI operation (e.g., Computer Use) to continue while the lid is closed.
- Privacy Focused: No telemetry, no account requirements, and limited network use for updates.
Related
- Dispatch
- Dispatch
- Project
- Project