Prevent Mac sleep when make is running

OS X 10.8 “Mountain Lion” now includes a nice command /usr/bin/caffeinate which will prevent system from going to sleep while a program is running.

For example, if one morning you realize the build started yesterday isn’t done yet, because the Mac was asleep, you might want to start using this:

alias make='caffeinate make'
comments powered by Disqus