Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: what's the point of the precommand modifier - ?



Marc Chantreux wrote on Mon, 14 Sep 2020 06:15 +00:00:
> hello,
> 
> according to zshmisc(1):
> 
>        -      The command is executed with a `-' prepended to its 
> argv[0] string.
> 
> ok ... but why is it useful?

Most shells check whether their argv[0] starts with a "-", and if that's
the case, they behave as login shells (as though -l was passed).

The effect can also be achieved with ARGV0; see zshparam(1).

Cheers,

Daniel




Messages sorted by: Reverse Date, Date, Thread, Author