If you’re a rookie getting your hands around all this webdev stuff, and you’re on a Mac, you may have already come to a rude awakening when you find out that, for reasons unknown to man, Mac decided we didn’t need wget.
That’s how I was introduced to Homebrew.
I love wget, because it’s a super simple and fast way to download something. wget http://wordpress.org/latest.zip
is the fastest way for me to download a zip, and I use it regularly. So one day, when deving code, I realized I needed a plugin. I went to wget it and got a horrible message.
-bash: wget: command not found
After searching around, I was about to download, compile, and install wget when a comment on StackExchange said “Try Homebrew.”
Everyone’s dersive comments aside about how ‘real’ programers don’t install packages (seriously people), I said to myself “Ipstenovich,” I said. Yes, I call myself that sometimes. “You use yum to install packages on your server because it’s easier and safer. Why wouldn’t you use the same thing here?” Over to http://brew.sh/ I went and stared at the installer command like a fish.
ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
The call ‘ruby -e’ means “run Ruby and tell it to call this URL externally…” And then it clearly was calling github for an installer. It’s tough to decide to trust a new program but after some serious banging around, I trust the Homebrew.
Once installed, which doesn’t take long at all, I ran the check brew doctor
which told me a couple things:
- I’d installed SVN and Git on my own (truth) so I needed to change my .profile (with directions how)
- I had a half-baked attempt at installing ImageMagick that needed cleaning (with suggestions how)
- I had MacPorts still in my /opt/ folder, that needed removing (with directions how)
- I needed to install xcode command line tools (with directions how)
- xQuartz was out of date
- I hadn’t updated my brew list in a bajillion years
Most people won’t have that last one. I did once have an older install of Homebrew that I’d never really cleaned up. However the other ones took me about an hour to clean up properly, because I was watching Fargo (the movie) at the time. Once installed and set up, I was able to install wget and upgrade it. Ditto OpenSSL (because Heartbleed, you know). It’s great.
Homebrew is pre-1.0 which means there can and will be issues. Don’t panic, for most of what anyone needs, this is perfect. It’s also good at upgrading when you need to:
The little beer mug is awesome.
One of the nice things about Homebrew is that it doesn’t use (nor advocate the use of) sudo. This is really good for security and makes me feel much safer.
Go forth, rookies, and install Homebrew! It will make your development much happier!