]> git.ipfire.org Git - thirdparty/git.git/commit - t/check-non-portable-shell.pl
t/check-non-portable-shell: detect "FOO= shell_func", too
authorJonathan Nieder <jrnieder@gmail.com>
Thu, 26 Dec 2019 19:57:47 +0000 (11:57 -0800)
committerJunio C Hamano <gitster@pobox.com>
Wed, 15 Jan 2020 22:02:32 +0000 (14:02 -0800)
commita7fbf12f2f31cb5aefb4fe7f467564be32c62968
tree412eaa3d88773a3d2d217c895fb3198fceb6d11a
parentc7973f249ebe86f10ec4b420a8ab83b8b83bce22
t/check-non-portable-shell: detect "FOO= shell_func", too

Just like assigning a nonempty value, assigning an empty value to a
shell variable when calling a function produces non-portable behavior:
in some shells, the assignment lasts for the duration of the function
invocation, and in others, it persists after the function returns.

Signed-off-by: Jonathan Nieder <jrnieder@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
t/check-non-portable-shell.pl