Created
March 2, 2017 13:02
-
-
Save kaeff/6b332c9a642cf92fd951db92592880e0 to your computer and use it in GitHub Desktop.
Utility to find apps which are missing from `brew list` although installed
This file contains hidden or 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 | |
brew cask list | sed 's/ +/\n/g' | sort > apps-cask.txt | |
ls -l /Applications | cut -c 55- | grep -v '\->' | sed 's/ /-/g' | sed 's/\.app//g' | awk '{print tolower($0)}' | sort > apps.txt | |
comm -23 apps.txt apps-cask.txt > apps-not-installed-by-brew.txt | |
ls /usr/local/Homebrew/Library/Taps/caskroom/homebrew-cask/Casks | sed 's/\.rb//' > all-casks.txt | |
comm -12 apps-not-installed-by-brew.txt all-casks.txt > apps-missing-from-brew.txt | |
cat apps-missing-from-brew.txt |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment