I just followed the instructions @ this question in order to get git autocompletion in the terminal. Here are the steps I've undertaken:
port install bash-completion
if [ -f /opt/local/etc/bash_completion ]; then . /opt/local/etc/bash_completion echo "bash completion loaded" fi
to my ~/.profile
port update git-core +svn +bash_completion +doc
Then I restarted the terminal, it showed me "bash completion loaded" so obviously the file exists, but the tab-completion still only works on files. Nothing magical happening after typing
git and then hitting tab.
/opt/local/etc/bash_completion.d/ and it gives me 149 files including
port. I tried typing those commands and then hitting tab but nothing worked there either.
Does anyone have an idea what I did wrong? Maybe I messed up a environment variable or something. Can anyone who has bash-completion install tell me a command where it should work , like
port up and then hit tab -->
Found another link that describes my approach: How to get git-completion.bash to work on Mac OS X?