When functions or scripts use any command wrapped by this plugin, they use the wrapped version, not the original. Since this plugin wraps various common commands such as env, this can cause issues such as acomagu/fish-async-prompt#67.
Is it possible to check inside the wrapped function if it's being run directly in the terminal and not from another function? I tried something putting something like this in grc.fish but just couldn't get it to work:
for executable in $execs
if type -q $executable
function $executable --inherit-variable executable --wraps=$executable
if test (status stack-trace | wc -l) -le 2
grc.wrap $executable $argv
else
eval $executable $argv
end
end
end
end
When functions or scripts use any command wrapped by this plugin, they use the wrapped version, not the original. Since this plugin wraps various common commands such as
env, this can cause issues such as acomagu/fish-async-prompt#67.Is it possible to check inside the wrapped function if it's being run directly in the terminal and not from another function? I tried something putting something like this in grc.fish but just couldn't get it to work: