Meet Homebrew- a Painless Way to Install Anything on your Mac
The chances are good that you install a gazillion software on your Mac if you’re a developer and run macOS. Server software, libraries, build systems, compilers, virtual machines, and fixes! You may think that installing software on Mac involves dragging an application icon to the Applications folder.
Seems easy peasy lemon squeezy? No, it isn’t what you think. What about the configuration files the application generates?
You’ve spent your precious time configuring something, and now you see the application broken. While uninstalling the application, you also have to deal with delinquent data files scattered on your hard drive. And, this eats up precious drive- if you’re not careful.
Thus, it is always better to track everything, that is the installing and uninstalling software. Don’t know what it is? It turns out there it is! Meet Homebrew.
Homebrew has the reputation of being “the missing package for managing macOS”. Know that it is a free yet open-source software package management system that simplifies software installation on macOS and Linux. The entire essence behind Homebrew’s name goes with the idea of building a Mac software, which depends on the user’s taste, in the end.
Now that you’re aware of the Homebrew, learning about installing the software seems like the best option. You can also skim through valuable resources like https://setapp.com/how-to/install-homebrew-on-mac for checking out how to use it. It is pretty easy to install homebrew. All you’ve to do is open a terminal and run the package. Follow some steps to install the same on your device.
Finding Packages to install:
To find the packages to install, run:
$ brew search <name>.
Although, a quick Google search for <package name> homebrew suffice your needs. Once you find the package you’re willing to install, there is a need to install it.
Say, you wish to install Node.js on your device. Do the following:
$ brew install node
The command searches all of the taps that configures Homebrew and then finds a matching formula along with a provided name. Know that Node has its location in the default core tap. Yet, the experts say that finding the formula may be difficult at times, thereby considering adding a new tap.
Adding Taps (Repositories)
If your homebrew doesn’t help you with finding the package you’re looking for, it may be in a different repository. As already mentioned, homebrew/ core is already “tapped” for you. To view the same, all you’ve to do is:
$ brew tap
To add new taps, click on new taps, use one of the commands like
$ brew tap <user>/<repo>
The command assumes that the repository is hosted on Github and is a shorthand. If you wish to tap repositories hosted somewhere else, use
$ brew tap <user>/<repo> <URL>
After tapping into a new repository, consider installing the formula. To find new repositories, a quick Google search might suffice your needs. Know that Homebrew keeps the package list and other versions in the local cache. Know that the cache may be outdated, and it may cause you to install outdated software. Thus, always keep your tabs fresh, if you want to correct this.
Keeping Tabs fresh:
Before running brew install, it is wise to get the latest version of the formulae. The process for the same is pretty simple. Use
$ brew update
Installing packages will then get you to the latest version. Also, consider keeping yourself up-to-date about other brew commands.
Upgrading local packages:
Software is known to move fast. Packages get updated routinely. Thus, you can always upgrade the installed formulae by running:
$ brew upgrade
The process takes over the installed formulae, check taps for newer versions and automatically installs the new-fangled versions.
$ brew update && brew upgrade
This command helps you in keeping away from the non-latest package versions.
Now that you want to uninstall a pack, use
$ brew uninstall <formula>
Yet, homebrew keeps the old version packages and thus, you might have Node.js binary versions present in your cellar. Run the following command if you find yourself strapped for hard-drive space.
$ brew uninstall -f node
This command helps you uninstall all versions of the node package.
To remove old package versions, consider freeing up some space. You can consider running commands like
$ brew cleanup
This command cleans the older versions, locks files and outdated files. Thus, you’ll be glad to notice a hard drive that’s squeaky clean!
When you do this, it cleans up old versions, outdated folders, locks files, keeping your hard drive squeaky clean!
Although Homebrew introduces nomenclature, which can be off-putting to the beginner, know it is a capable software that has earned its reputation as a de facto package manager in the mac/OS system.
Hopefully, you were able to learn the way of installing and using Homebrew. After all, it helps you in managing software on Mac. If it did help you, ensure to clap it up!
A passionate blogger and technology hunger by Mind. I have more than 15 years of experience in tech product research and consumer relation. Started BestDigiProduct as Journey to connect Consumers to the right product. The mantra of life is “Life is like ice cream, eat it before melting”.