EyeHack
A macOS menubar app that enforces the 20-20-20 rule: every 20 minutes it hijacks every display for 20 seconds so your eyes get an unavoidable break.
What it does
- Sits silently in the menubar — invisible while you work.
- Every 20 minutes triggers a full-screen overlay across all connected displays.
- Overlay randomly rotates between three break modules (never repeats the same one twice in a row):
- Distance Illusion — a hybrid optical illusion whose image shifts depending on viewing distance, training the eye to refocus.
- Sci-Zen — a minimal breathing prompt.
- Brain Reset — a riddle with a delayed answer reveal.
- Skips breaks automatically when the screen is recording, the camera is active, or a meeting app is holding the display awake.
- Resets its timer after sleep, so there's no surprise break at 9 a.m.
- Plays a completion sound when the break ends.
- No dismiss-early button.
Stack
| Layer | Tech |
|---|---|
| Backend | Rust, Tauri v2 |
| Frontend | React 19, TypeScript, Vite |
| Styling | Tailwind CSS |
| Package manager | pnpm |
Meeting / recording detection
Breaks are skipped when any of these are true:
| Signal | Detection |
|---|---|
| Screen recording active | ioreg — CGSIsCapturing key present |
| Camera in use | pgrep -x VDCAssistant succeeds |
| Meeting app holding display awake | pmset -g assertions contains PreventUserIdleDisplaySleep + a known app name |
Apps checked: Zoom, Google Chrome, Brave Browser, Teams, Slack.
Sleep awareness
The 20-minute timer uses SystemTime (wall clock) rather than Instant (monotonic, which pauses during sleep). If the gap between ticks exceeds 3 minutes the system was asleep — the accumulator resets and gives a fresh 20-minute window after wake.
Auto-updates
Install once and forget. New versions arrive on their own — the app quietly checks at launch and offers to update. There's a "Check for Updates…" item in the tray menu if you're impatient.

