From: Junio C Hamano Date: Fri, 26 Jul 2024 18:38:39 GMT Subject: Re: [PATCH v2 0/5] improve one-shot variable detection with shell function Message-ID: In-Reply-To: <20240726081522.28015-1-ericsunshine@charter.net> Eric Sunshine writes: > @@ t/t3430-rebase-merges.sh: test_expect_success 'refuse to merge ancestors of HEAD > git checkout --orphan unrelated && > - (GIT_AUTHOR_NAME="Parsnip" GIT_AUTHOR_EMAIL="root@example.com" \ > - test_commit second-root) && > -+ test_env GIT_AUTHOR_NAME="Parsnip" GIT_AUTHOR_EMAIL="root@example.com" \ > -+ test_commit second-root && > ++ test_commit --author "Parsnip " second-root && Very pleasing to the eyes. > @@ t/check-non-portable-shell.pl: sub err { > err q(quote "$val" in 'local var=$val'); > - /^\s*([A-Z0-9_]+=(\w*|(["']).*?\3)\s+)+(\w+)/ and exists($func{$4}) and > + /\b([A-Z0-9_]+=(\w*|(["']).*?\3)\s+)+(\w+)/ and !/test_env.+=/ and exists($func{$4}) and > - err '"FOO=bar shell_func" assignment extends beyond "shell_func"'; > + err '"FOO=bar shell_func" is not portable (use test_env FOO=bar shell_func)'; OK. Thanks. Will queue.