Skip to content

Instantly share code, notes, and snippets.

@diasjorge
Created January 14, 2013 10:31
Show Gist options
  • Save diasjorge/4529167 to your computer and use it in GitHub Desktop.
Save diasjorge/4529167 to your computer and use it in GitHub Desktop.
Clean Unused bash completions
cd /usr/local/etc/bash_completion.d
for f in *
do
if [[ $f =~ git|helpers ]]; then
echo "MATCH"
fi
exists=$(which $f)
if [[ -z $exists ]]; then
rm $f
fi
done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment