add yazi config

This commit is contained in:
Alexander Navarro 2024-02-14 19:53:01 -03:00
parent 1bd7e9f81f
commit 37999bc9b1
4 changed files with 529 additions and 0 deletions

View file

@ -51,3 +51,12 @@ help() {
fzf-jq() {
echo '' | fzf --print-query --preview="jq -r {q} <$@"
}
function ya() {
local tmp="$(mktemp -t "yazi-cwd.XXXXX")"
yazi "$@" --cwd-file="$tmp"
if cwd="$(cat -- "$tmp")" && [ -n "$cwd" ] && [ "$cwd" != "$PWD" ]; then
cd -- "$cwd"
fi
rm -f -- "$tmp"
}