This morning I opened my laptop like any other work morning, attempted to run my test suite and got a nice friendly error.
dyld: Library not loaded: /usr/local/opt/openssl/lib/libcrypto.1.0.0.dylib Referenced from: /usr/local/bin/php Reason: image not found  1634 abort php
I did some digging and found that the error was caused by some OpenSSL thing. I tried installing, uninstalling and reinstalling openssl so many times using Homebrew.
After I spent an hour of playing around, I decided to sync my backups, push up to Github and reset my Mac.
So that's what I did. When I went through the reset process, I did hope it was going to offer me Catalina but it just gave me Mojave. Not a big deal.
Anyway, unlike some others, I actually enjoy resetting my Macs. Mainly because I have a bash script that installs all my Mac apps and developer dependencies for me.
Without that script, I'd still be here (at 10:26pm when writing) installing everything I need and configured how I want it.
I also use a bit of software called Mackup which saves software configurations for things like PHPStorm and iTerm so I don't have to manually export and import my settings.
However, for most software you need to login to an account so that's a manual process but you could probably do that while the script is running.
Thankfully, I was able to get most of the stuff I need setup by 4pm. I'm also glad I wasn't booked in for any work today or that would have to be postponed until Monday.
Anyways, after my long tangent that you might not be able to understand. My point is that having a dotfiles repository and an install script can really help you out if you're laptop was to die or some binary was to corrupt like in my case. You can get back up and running in no time!
In fact, if you want to checkout my
dotfiles they're in an open-source repo so you can stalk them to your hearts content. (stalk the files, not me).
Not to show off but my dotfiles are mentioned in a Scotch.io article.