Last active
March 30, 2024 21:08
-
-
Save dolmen/ecabdd0a16bc6dbc87b4ef9ca97767c9 to your computer and use it in GitHub Desktop.
check-xz-in-homebrew
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# Commands to evaluate impact of xz installed via homebrew. | |
# Author: Olivier Mengué. | |
# Show info about xz bottle: | |
brew info xz | |
# Upgrade xz: | |
brew update | |
brew upgrade xz | |
# Show bottles which directly depend on xz (as JSON lines): | |
brew info --installed --json | jq -c '.[] | select(.dependencies | index("xz")) | {(.name): .dependencies}' | |
# Show bottles which directly depend on xz (as text): | |
brew info --installed --json|jq -cr '.[]|select(.dependencies|index("xz"))|(.name + ": " + (.dependencies | join(", ")))' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment