mirror of
https://git.in.rschanz.org/ryan77627/guix-config.git
synced 2025-01-31 09:51:16 -05:00
13 lines
366 B
Fish
13 lines
366 B
Fish
function __zoxide_z
|
|
set --local argc (count $argv)
|
|
if test $argc -eq 0
|
|
__zoxide_cd $HOME
|
|
else if test "$argv" = -
|
|
__zoxide_cd -
|
|
else if test $argc -eq 1 -a -d $argv[1]
|
|
__zoxide_cd $argv[1]
|
|
else
|
|
set --local result (command zoxide query --exclude (__zoxide_pwd) -- $argv)
|
|
and __zoxide_cd $result
|
|
end
|
|
end
|