Skip to content

Instantly share code, notes, and snippets.

@jstotz
Created March 5, 2010 15:05
Show Gist options
  • Save jstotz/322779 to your computer and use it in GitHub Desktop.
Save jstotz/322779 to your computer and use it in GitHub Desktop.
# rake/cap task completion
export COMP_WORDBREAKS=${COMP_WORDBREAKS/\:/}
_rakecomplete() {
COMPREPLY=($(compgen -W "`rake -s -T 2>/dev/null | awk '{{print $2}}'`" -- ${COMP_WORDS[COMP_CWORD]}))
return 0
}
complete -o default -o nospace -F _rakecomplete rake
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment