Skip to content

Instantly share code, notes, and snippets.

@chadhs chadhs/_completemarks

Last active Dec 21, 2015
Embed
What would you like to do?
update to mark autocomplete function for mac os x found here: http://jeroenjanssens.com/2013/08/16/quickly-navigate-your-filesystem-from-the-command-line.html
_completemarks() {
local curw=${COMP_WORDS[COMP_CWORD]}
local wordlist=$(find $MARKPATH -type l | sed -En 's/(.*)\/.(marks)\/(.*)/\3/p')
COMPREPLY=($(compgen -W '${wordlist[@]}' -- "$curw"))
return 0
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.