flake and yazi script
This commit is contained in:
parent
77a34cc7d1
commit
268ff58ac0
2 changed files with 19 additions and 24 deletions
|
@ -1,10 +1,5 @@
|
|||
#!/usr/bin/env fish
|
||||
|
||||
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" ]
|
||||
builtin cd -- "$cwd"
|
||||
end
|
||||
rm -f -- "$tmp"
|
||||
wezterm --config-file ~/.config/wezterm/launcher.lua start --always-new-process --cwd (pwd) yazi &
|
||||
end
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue