wrappers/fish: add yazi

This commit is contained in:
Nikodem Rabuliński 2024-09-14 18:38:27 +02:00
parent 38243524d5
commit 69ea07184f
2 changed files with 9 additions and 0 deletions

View file

@ -25,4 +25,12 @@ and begin
# Integrations
zoxide init fish | source
direnv hook fish | source
function y
set tmp (mktemp -t "yazi-cwd.XXXXXX")
yazi $argv --cwd-file="$tmp"
if set cwd (command cat -- "$tmp"); and [ -n "$cwd" ]; and [ "$cwd" != "$PWD" ]
__zoxide_cd_internal -- "$cwd"
end
rm -f -- "$tmp"
end
end