From: Junio C Hamano <junio@pobox.com>
To: Jeff King <peff@peff.net>
Cc: git@vger.kernel.org
Subject: Re: [PATCH 1/4] fix bsd shell negation
Date: Tue, 13 May 2008 19:27:54 -0700 [thread overview]
Message-ID: <7viqxhr55h.fsf@gitster.siamese.dyndns.org> (raw)
In-Reply-To: <20080513084452.GA23799@sigill.intra.peff.net> (Jeff King's message of "Tue, 13 May 2008 04:44:52 -0400")
Jeff King <peff@peff.net> writes:
> On some shells (notably /bin/sh on FreeBSD 6.1), the
> construct
>
> ! foo | bar
>
> does not negate the exit value of the pipeline, but rather
> of 'foo', producing the opposite of the expected value. We
> can work around this by specifying it as
>
> ! (foo | bar)
After applying this patch, we still seem to have fair number of hits:
$ git grep -n -e '![^(]* |' -- '*.sh'
t/t5302-pack-index.sh:68: ! echo "$msg" | grep "pack too large .* off_t"
t/t7002-grep.sh:111: ! git grep -c test $H | grep -q /dev/null
t/t7600-merge.sh:378: if ! grep "^ file | *2 +-$" diffstat.txt
t/t7600-merge.sh:392: if ! grep "^ file | *2 +-$" diffstat.txt
t/t9400-git-cvsserver-server.sh:160: ! cat request-anonymous |
t/t9400-git-cvsserver-server.sh:169: ! cat request-anonymous |
t/t9400-git-cvsserver-server.sh:187: ! cat request-anonymous |
Didn't you have trouble with them, or the tests themselves are broken in
some other way that these did not triggger?
next prev parent reply other threads:[~2008-05-14 2:29 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-05-13 8:43 [PATCH 0/4] freebsd portability fixes Jeff King
2008-05-13 8:44 ` [PATCH 1/4] fix bsd shell negation Jeff King
2008-05-14 2:27 ` Junio C Hamano [this message]
2008-05-14 4:01 ` Jeff King
2008-05-13 8:45 ` [PATCH 2/4] t5000: tar portability fix Jeff King
2008-05-13 8:45 ` [PATCH 3/4] clone: bsd shell " Jeff King
2008-05-13 8:46 ` [PATCH 4/4] filter-branch: fix variable export logic Jeff King
2008-05-14 4:18 ` Junio C Hamano
2008-05-14 4:57 ` Jeff King
2008-05-14 9:33 ` Paolo Bonzini
2008-05-13 9:04 ` [PATCH 0/4] freebsd portability fixes Jeff King
2008-05-13 20:39 ` Alex Riesen
2008-05-13 20:44 ` Alex Riesen
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=7viqxhr55h.fsf@gitster.siamese.dyndns.org \
--to=junio@pobox.com \
--cc=git@vger.kernel.org \
--cc=peff@peff.net \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).