I kept seeing `caffeinate` suggested under long-running agent threads, so the short version is: it prevents idle sleep. Closing the lid uses a different macOS sleep path, which is why a build or agent can still stop the second you shut the MacBook.
If you only need to lock the screen or walk away with the lid open, `caffeinate -i` is enough. For closed-lid work, you need something that changes the lid behavior and, just as importantly, restores it afterwards. That distinction is what pushed me to build Clamshell.
Curious how other people handle long local agent jobs: leave the lid cracked, use cloud agents, or change the Mac s sleep behavior?
Clamshell
Thanks Gal. The clam should turn blue as soon as Clamshell is actually armed, so if yours stayed gray that sounds like something went wrong. Did it stay unchanged after you armed it?