Skip to content

Instantly share code, notes, and snippets.

@begoon
Forked from eguven/brew-list.sh
Created January 6, 2021 19:35
Show Gist options
  • Save begoon/4a765eb10d9915c11fcd485248b3b99b to your computer and use it in GitHub Desktop.
Save begoon/4a765eb10d9915c11fcd485248b3b99b to your computer and use it in GitHub Desktop.
List all packages installed using Homebrew and their sizes
brew list --formula | xargs -n1 -P8 -I {} \
sh -c "brew info {} | egrep '[0-9]* files, ' | sed 's/^.*[0-9]* files, \(.*\)).*$/{} \1/'" | \
sort -h -r -k2 - | column -t
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment