I love Homebrew, but sometimes it really gets me down, you know?
Especially when I have to deal with
launchctl loads and unloads services that start at login. In OS X, these
services are represented by files ending with
.plist (which stands for
“property list”). These plists are usually stored in either
/Library/LaunchAgents. You load them (i.e. tell
them to start at login) with
launchctl load $PATH_TO_LIST and unload them with
launchctl unload $PATH_TO_LIST. Loading a plist tells the program it
redis) to start at login, while unloading it tells the program
not to start at login.
This post-install message from Homebrew may look familiar:
To have launchd start mysql at login:
ln -sfv /usr/local/opt/mysql/*.plist ~/Library/LaunchAgents
Then to load mysql now:
launchctl load ~/Library/LaunchAgents/homebrew.mxcl.mysql.plist
Or, if you don't want/need launchctl, you can just run:
Doing all that takes too long, and I can never remember where Homebrew plists
are. Fortunately, Homebrew includes a lovely interface for managing this without
launchctl or knowing where plists are.
This is fantastic. I’ll be checking out cask tomorrow for sure.