new script: envwrap

This commit is contained in:
crater2150 2023-08-29 11:31:35 +02:00
parent 3cb3440d80
commit 1983156528

6
misc/envwrap Executable file
View file

@ -0,0 +1,6 @@
#!/bin/zsh
source ${$(realpath "$0"):h:h}/lib/next-in-path.zsh
program="${0:a:t}"
envwrapconf=${XDG_CONFIG_HOME:-$HOME/.config}/envwrap/$program
[[ -e $envwrapconf ]] && source $envwrapconf
$(next-in-path "$program" $0) "$@"