1
0
mirror of https://github.com/wting/autojump synced 2024-10-27 20:34:07 +00:00
wting_autojump/_j
Simon Marache-Francisco 904fc8b744 cleaned the code
2009-03-30 13:40:48 +02:00

12 lines
235 B
Plaintext
Raw Blame History

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

#compdef j
cur=${words[2, -1]}
ret=$(autojump --completion "${cur[*]}")
if [ "$ret" != "" ]; then # if at least one answer
for i in $(echo "$ret"); do
compadd -U $i # add all of them as possible completion
done
fi