← Home![]()
2026 · personal · private
greendot
Keep the Slack green dot on while you are away
What it does
Keeps Slack (and other messengers) showing you as active while you are away. Two things at once:
- Sleep prevention: keeps the system and display awake.
caffeinateon macOS,SetThreadExecutionStateon Windows. - Mouse jiggle: periodically moves the mouse 1px and back, generating a real input event to defeat “no input for 30 minutes → away”.
Design
- The working code uses only the standard library (ctypes). Only the tray icon needs pystray + Pillow; without them, it runs as a window.
- Closing the window hides to the tray instead of quitting. Green = running, gray = stopped.
- Settings (interval, options, auto-stop, window position) are saved; launch at login via the Windows Run key or macOS LaunchAgents; an auto-stop timer prevents leaving it on all night.
- On Windows, PyInstaller produces a single ~19 MB exe that runs on a PC without Python. Batch-script variants remain for environments that block the exe.
Status
Verified live on macOS; the Windows build is unverified.