Subject: Re: difftool: honor --trust-exit-code for builtin tools

From: Aaron Schrab <[email-masked]>
Date: Mon, 17 Nov 2014 17:15:37 -0500

At 10:11 -0800 16 Nov 2014, Junio C Hamano <[email-masked]> wrote:
>It does not have any significance that a random shell implementation
>is not POSIX compliant.  That would merely mean that such a shell
>cannot be used to run POSIX shell scripts like our Porcelain.

Right, and I suspect that it's very rare for zsh to be used as /bin/sh.  
I've heard of people doing it just to see what would fail, but not of 
anybody doing that for regular use.

>I would suspect that zsh has more "posixly correct" mode, with which
>it _can_ run POSIX shell scripts, and I would imagine that this 
>"$status is an alias $?" business is disabled in that mode? 

Yes, if zsh is invoked as either "sh" or "ksh" it attempts to emulate 
the usual semantics of the named shell.  One of the differences is that 
$status isn't special in the emulation modes.