Denton Liu <liu.denton@xxxxxxxxx> writes: >> Here, $command may or may not be a git command and more importantly, >> it could be a shell function, right? Then we need to take it into >> account that >> >> VAR=VAL shell_function args... >> >> will not work, no? >> >> Some shells do not make this a single-shot environment variable >> assignment that will not persist once the single function invocation >> returns. > > ... > which makes me suspect that these shells are not POSIX-compliant. What > are some examples of shells that behave this way? I think the most relevant thread is the one that contains this message: https://public-inbox.org/git/7vljfzz0yd.fsf@xxxxxxxxxxxxxxxxxxxxxxxx/ FWIW, shells that do not retain the assignment after a function returns are not POSIX compliant.