AutoYADM commit: 2025-04-22 14:05:13

This commit is contained in:
Daniel Fichtinger 2025-04-22 14:05:13 -04:00
parent 93f3562923
commit 65272a1ba3

View file

@ -17,10 +17,26 @@ function find_pdf
end
end
if set -q _flag_q
set ret 1
else
set ret 0
end
function qecho
if not set -q _flag_q
echo $argv[1]
end
end
set -l src (path resolve $argv[1])
# echo $src
# string replace
set -l targ (string replace --filter '.typ' '.pdf' $src)
if not string match -q '.typ' $src
qecho "$(path basename $src) is not a Typst file!"
return $ret
end
set -l targ (string replace '.typ' '.pdf' $src)
set -l base (path basename --no-extension $src).pdf
if test -f "$targ" -a '' != ''
# zathura "$targ" &>/dev/null &