update yazi config

This commit is contained in:
Alexander Navarro 2025-01-28 14:43:51 -03:00
parent e67f758e35
commit 42735952be
5 changed files with 304 additions and 364 deletions

View file

@ -42,10 +42,10 @@ fzf-jq() {
}
function yy() {
local tmp="$(mktemp -t "yazi-cwd.XXXXX")"
local tmp="$(mktemp -t "yazi-cwd.XXXXXX")" cwd
yazi "$@" --cwd-file="$tmp"
if cwd="$(cat -- "$tmp")" && [ -n "$cwd" ] && [ "$cwd" != "$PWD" ]; then
\cd -- "$cwd"
if cwd="$(command cat -- "$tmp")" && [ -n "$cwd" ] && [ "$cwd" != "$PWD" ]; then
builtin cd -- "$cwd"
fi
rm -f -- "$tmp"
}