8 ms·
And here's a completion code that works for Mac OS: function _jump { local cur=${COMP_WORDS[COMP_CWORD]} local marks=$(find $MARKPATH -type l | a
by beders 13y ago
And here's a completion code that works for Mac OS:
function _jump {
local cur=${COMP_WORDS[COMP_CWORD]}
local marks=$(find $MARKPATH -type l | awk -F '/' '{print $NF}')
COMPREPLY=($(compgen -W '${marks[@]}' -- "$cur"))
return 0
}
complete -o default -o nospace -F _jump jump
- cachvico 13y agoShouldn't this be complete -o default -o nospace -F _jump jump unmark and then it simply replaces the existing _completemarks(), instead of needing both?