This repo is a collection of bash completion scripts that work on my Mac. They probably work for yours too. Each bash_completion script has been taken from a different source and all should have their licenses at the top of the file. The only thing in this repo that is my work is the import.sh script that anyone could write. This script does not currently install anything for you. You have to copy the contents into either /etc/profile for system-wide application or in your own .bash_profile for user-wide application. At some point in the future I'll probably make an install script. I don't set up systems often enough to need a script yet.
##System-wide Installation
- You need
sudorights. If you don't have them, skip to the next section to install only for your user. - Copy the entire
bash_completion.ddirectory to/usr/local/etc/bash_completion.d(remember this destination directory as_base) - Open
/etc/profilewith the text editor of your choice and add the contents ofimport.shto the end of it - Find
_base="/usr/local/etc/bash_completion.d"and make sure it matches the_basedestination above - Save & you're done!
##Per-user Installation
- Copy the entire
bash_completion.ddirectory to~/Library/bash_completion.d(remember this destination directory as_base) - Open
~/.bash_profilewith the text editor of your choice and add the contents ofimport.shto the end of it - Find
_base="/usr/local/etc/bash_completion.d"and make sure it matches the_basedestination above (~/Library/bash_completion.d) - Save & you're done!
If you already have a terminal window open these changes won't take effect in it, but if you open a new one you're good to go.