zoxide/functions/z.fish
2020-03-08 18:17:05 +02:00

16 lines
378 B
Fish

function z
if test (count $argv) -gt 0
set _Z_RESULT (zoxide query $argv)
switch "$_Z_RESULT"
case 'query: *'
cd (string sub -s 8 -- "$_Z_RESULT")
commandline -f repaint
case '*'
if test -n "$_Z_RESULT"
echo "$_Z_RESULT"
end
end
end
end