Created
March 29, 2012 09:39
-
-
Save jacobat/2235434 to your computer and use it in GitHub Desktop.
Fast rake completion with zsh
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#compdef rake | |
if [[ -f Rakefile ]]; then | |
sum=`md5 -q Rakefile **/*.rake | md5` | |
if [[ ! -f .rake_tasks.$sum~ ]]; then | |
rake -s --tasks | cut -d ' ' -f 2 > .rake_tasks.$sum~ | |
fi | |
compadd $(cat .rake_tasks.$sum~) | |
fi |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment