On Fri, Mar 22, 2013 at 03:56:15PM +0100, Yann Droneaud wrote:
> Le 22.03.2013 15:48, Junio C Hamano a écrit :
> >>It's not in final shape: the line
> >> EDITOR=false test_must_fail git merge signed
> >Because test_must_fail is a shell function, single-shot environment
> >assignment like this should not be used.
> It's used throughout the test. The test 'merge --no-edit tag should
> skip editor' is using it.
It's OK to do:
and it's OK to do:
but it's not OK to do:
SINGLE_SHOT=foo some_function args
Because some POSIX shells do not create a new environment for the
function (and SINGLE_SHOT will persist after the call, polluting the
> Before posting my half useful test, I used "EDITOR=false
> test_must_fail set" in --verbose mode to find if EDITOR was correctly
> defined passed test_must_fail, and it was.
I do not think there is a shell that does not set it; it is only that
some shells do not _unset_ it.
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majord...@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html