brew cask VS brew formula
Homebrew for macOS
Since reinstalling certain software packages on my Linux desktop, Linux laptop and Macbook a few times in the past months, I’m positively in love with the Homebrew project. Today I’ll share my understanding of its basic deployment modules: casks vs formulae.
What Homebrew does
Homebrew project is the magic behind brew command – it’s a software manager that assists with source-code and binary distributions of various software projects.
Specifically, brew is popular on macOS platform where most of software is traditionally installed using graphical user interface (GUI) or via AppleScript automation. Recent versions of macOS exposed a number of relevant interfaces via command line, but average user (and most of advanced users/developers) still had to resort to some enterprise level proprietary delivery and installation mechanism.
With the arrival of Homebrew, things got much easier. A typical software installation is now simpler and quite comparable to the number of steps required in other Unix and Unix-like operating systems:
- You enable relevant software repo
- You install software package
With brew, first install is similar:
- You install Homebrew
- You install software package
But later things get even simpler:
You simply use brew to install software package
This is mostly due to the fact that Homebrew supports both standard and third-party software using its own centralised approach to software packaging. Application owners define a formula for installing their software, get in touch with Homebrew team to add it to the project, and going forward things happen pretty much automatically.
In Linux world, many software packages are still distributed independently or have to make their way into a specific application/software store – so many small projects are hard to find.
brew formula
Each Open Source package integrated with Homebrew is configured using a brew formula. It’s a Ruby language based configuration file that explains how the software can be downloaded from GitHub or similar repository and then compiled.
Here’s a formula for htop command:
brew install
Installing software from brew formulae is easy:
brew cask
brew cask is an extension to standard brew based software management, it’s a type of formula that documents the process of installing a graphical application (and not entirely coincidentally closed-source software).
Similar to brew formula, cask defines where software can be downloaded and what dependenices it has, but specification is so flexible that you can even download binary packages from developer websites. If it’s a paid project, you’ll probably get a chance to download a trial copy (that you later can enable using a valid serial number for that software).
Here’s brew cask for my password manager of choice, 1Password:
brew cask install
Installing brew casks is easy:
That’s all I wanted to explain today. Let me know if you have any questions!
See Also
- Homebrew website
- Install Docker with brew
- Install Brave browser with brew
- Homebrew software
- Install Homebrew
- brew command is missing
- Homebrew in Linux
- macOS
- brew 2.0.0
- Install ZSH with brew
- screenFetch in MacOS (installed with Homebrew)
- MacOS commands
Homebrew for macOS
Since reinstalling certain software packages on my Linux desktop, Linux laptop and Macbook a few times in the past months, I’m positively in love with the Homebrew project. Today I’ll share my understanding of its basic deployment modules: casks vs formulae.
What Homebrew does
Homebrew project is the magic behind brew command – it’s a software manager that assists with source-code and binary distributions of various software projects.
Specifically, brew is popular on macOS platform where most of software is traditionally installed using graphical user interface (GUI) or via AppleScript automation. Recent versions of macOS exposed a number of relevant interfaces via command line, but average user (and most of advanced users/developers) still had to resort to some enterprise level proprietary delivery and installation mechanism.
With the arrival of Homebrew, things got much easier. A typical software installation is now simpler and quite comparable to the number of steps required in other Unix and Unix-like operating systems:
- You enable relevant software repo
- You install software package
With brew, first install is similar:
- You install Homebrew
- You install software package But later things get even simpler:
You simply use brew to install software package This is mostly due to the fact that Homebrew supports both standard and third-party software using its own centralised approach to software packaging. Application owners define a formula for installing their software, get in touch with Homebrew team to add it to the project, and going forward things happen pretty much automatically.
In Linux world, many software packages are still distributed independently or have to make their way into a specific application/software store – so many small projects are hard to find.
brew formula
Each Open Source package integrated with Homebrew is configured using a brew formula. It’s a Ruby language based configuration file that explains how the software can be downloaded from GitHub or similar repository and then compiled.
Here’s a formula for htop command:
brew install
Installing software from brew formulae is easy:
brew cask
brew cask is an extension to standard brew based software management, it’s a type of formula that documents the process of installing a graphical application (and not entirely coincidentally closed-source software).
Similar to brew formula, cask defines where software can be downloaded and what dependenices it has, but specification is so flexible that you can even download binary packages from developer websites. If it’s a paid project, you’ll probably get a chance to download a trial copy (that you later can enable using a valid serial number for that software).
Here’s brew cask for my password manager of choice, 1Password:
brew cask install
Installing brew casks is easy:
That’s all I wanted to explain today. Let me know if you have any questions!
See Also
- Homebrew website
- Install Docker with brew
- Install Brave browser with brew
- Homebrew software
- Install Homebrew
- brew command is missing
- Homebrew in Linux
- macOS
- brew 2.0.0
- Install ZSH with brew
- screenFetch in MacOS (installed with Homebrew)
- MacOS commands