Skip to content

homebrew and linuxbrew formula Notes

Chris edited this page Jan 19, 2018 · 48 revisions

Homebrew 🍻 formula are stored in the following location on macOS (10.12.6)

/usr/local/Homebrew/Library/Taps/homebrew/homebrew-core/Formula/

However, linuxbrew formula are more than likely located at the below path on Debian Jessie

/home/linuxbrew/.linuxbrew/Homebrew/Library/Taps/homebrew/homebrew-core/Formula/

To edit a formula, make sure the $EDITOR environment variable is set to your favorite text editor. ie. in the fish shell,

set -x EDITOR /path/to/your/favorite/editor

Example

set -x EDITOR /home/linuxbrew/.linuxbrew/bin/nvim

Then one can edit the formula of choosing with the below command,

brew edit <name_of_formula.rb>

Example

brew edit weechat.rb

To list all installed packages with homebrew 🍻

brew list
brew cask list

To get the SHA 256 has of a file

shasum -a 256 <name_of_file> | awk '{printf $1}' | pbcopy

Useful Links πŸ”—

How to Create and Maintain a Tap
Formula Cookbook for developers
Python for Formula Authors
A deep dive 🏊 into homebrew dependencies

Clone this wiki locally