Skip to content

ivanzemskiy/brew-deps-tree

Repository files navigation

Brew maintenance

Cleanup problem

It's unclear which formulas are added only as build dependencies. As a result, it's difficult to understand which dependencies can be removed (saving disk space) without damaging other formulas.

brew list --installed-on-request
brew leaves --installed-as-dependency
brew deps --tree --installed

The --annotate flag does not work with --tree.

Helper script

Can help if you want to remove formulas / casks, but fair to break other formulas.

% ./scripts/brew_deps.py -h
usage: brew_deps.py [-h] [-t TARGET | -v | -q] [formula ...]

produces brew-tree.json which includes all the build/runtime/test ... dependencies

json can be quickly viewed using jg or a similar tool

About

Generates brew-flat.json and brew-tree.json with all the build/runtime/test dependencies.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published