Hello,

l...@gnu.org (Ludovic Courtès) skribis:

> $ sh -c 'exec -a FOO 
> /gnu/store/6vmniz83k46l8jpry50wdvwxsncz1r5w-khal-0.7.0/bin/.khal-wrap-01  
> --version'
> .khal-real, version 0.7.0

What happens is that ‘exec -a’ is doesn’t work when the wrapped program
is a script.

This is because, when invoked via a shebang (or when passed the file
name of a script), interpreters receive the file name of the script as
argv[1], and then typically shift argv to the left (argv[1] becomes
argv[0] etc.)

AFAICS there’s no generic solution to this problem.  :-/

Ludo’.

Reply via email to