Homebrew, the package manager

After installing MacPorts and doing the ‘sudo port select …’, ‘/usr/bin/env python’ should give you the right binary. What you need to look out for are references to /usr/bin/python.

Thank you! I am looking forward to giving MacPorts a go.

EDIT: Would you recommend doing this to use the latest version of Git?

Without knowing your use case it’s kinda hard to make a recommendation. Personally, I don’t use git yet, although I’m getting to the point where I’ll soon need to. If I were using git, and I was using it only for personal work, and only with xCode, I’d probably just use the Apple version unless that version was buggy or lacked some necessary feature. Otherwise, yes, I would install git via MacPorts.

I don’t know if it would be difficult to make xCode use that version, or even if you would want to. One faq about MacPorts is “Will my ports survive a major macOS upgrade?” and I believe the short answer is “No” (the same is true of Homebrew). This would mean, for example, that if you were using the MacPorts version with xCode and you upgraded to macOS 10.16 in the future, all of your xCode projects would be unavailable until you brought your ports up to speed.

1 Like

Homebrew handles upgrades to macOS really well, and it sounds like better than MacPorts. I don’t recall ever having a problem.

From the linked post:

  1. Run the macOS installer: startosinstall
  2. Run all macOS updates for Xcode, etc…: softwareupdate -ai
  3. Update homebrew itself and the package “lists”: brew update
  4. Upgrade all the software homebrew installed: brew upgrade
  5. Update any software installed with cask: brew cask upgrade

I don’t know how macports in keeping list of packages versions etc, but using homebrew one can install old versions. I had an issue where I see to install python 2 which is currently not avaiable on homebrew as it get deprecated but searching and going back in history in git make it work.

I’ve been wondering what casks were - thanks!

Also thank you for the brew-bundle link - didn’t even know that existed! Doubt I’d use it regularly, but nice to have for fast installs in case of drive replacement, nuke-and-pave, etc.

1 Like

While I’m not afraid of the terminal, Cakebrew is awesome! Thanks for that

1 Like

To update outdated Homebrew softwares, I found this interactive command-line tool better than the default one.

brew cu -a

carbon.png

3 Likes

What is the difference between brew and cask

Casks are GUI applications that brew can install, like 1Password, and about a thousand others.

“To install, drag this icon…” no more!
Homebrew Cask extends Homebrew and brings its elegance, simplicity, and speed to the installation and management of GUI macOS applications such as Atom and Google Chrome.
We do this by providing a friendly CLI workflow for the administration of macOS applications distributed as binaries.

I’m learning more about homebrew and have done a couple of things with it so far. I have a few questions and am hoping y’all can help answer

  1. I currently have 1password installed via dmg file. Can homebrew take over the installation or do I need to uninstall and then brew install?
  2. When an app that was installed via homebrew needs to get updated, are you able to go through the in-app update process or does it need to be via homebrew? Since I’m in the habit of updating when the app prompts, I wonder if I will need to retrain my brain.
  1. Not sure. I would do brew search 1password and see if it shows a checkmark (meaning installed) in the list. But based on the next answer, it probably won’t matter.

  2. Based on the docs, it looks like homebrew is intelligent about apps that update themselves.

Many applications update themselves, so their Casks are ignored by brew outdated and brew upgrade. This behaviour can be overridden by adding --greedy to the command.

  1. Looks like 1password isn’t installed from a brew perspective. I’ll get to it the next time I upgrade a machine.
  2. Thanks. Your google-fu is better than mine.
1 Like