All the Git at your fingertips — auto-completion

...want auto-completion for certain git commands?
Put this into your ~/.bash_profile  or ~/.bashrc:
    local cur prev opts
    opts="checkout commit branch push pull log reset status"
    if [[ ${cur} == * ]] ; then
        COMPREPLY=( $(compgen -W "${opts}"  ${cur}) )
        return 0
complete -F _git git


Popular posts from this blog

Tuning ext4 for performance with emphasis on SSD usage

NetBeans 6.1: Working with Google´s Android SDK, Groovy and Grails