Re: [PATCH 2/2] Allow passing pipes for input pipes to diff --no-index
- From
Taylor Blau <me@ttaylorr.com>
- Date
- Sep 18, 2020, 18:00 UTC
- Message-ID
- <20200918180043.GB149847@nand.local>
- In-Reply-To
- <20200918172044.GB183026@coredump.intra.peff.net>
On Fri, Sep 18, 2020 at 01:20:44PM -0400, Jeff King wrote:
Show 7 quoted lines
> On Fri, Sep 18, 2020 at 10:36:47AM -0400, Taylor Blau wrote: > > > - The cat pipe is unnecessary, and is also violating a rule that we > > don't place 'git' on the right-hand side of a pipe (can you redirect > > the file at the end instead?). > > What's wrong with git on the right-hand side of a pipe?
Ack, ignore me. The problem would be on the left-hand side only, without set -o pipefail, which we don't do.
Show 6 quoted lines
> On the left-hand side we lose its exit code, which is bad. But on the > right hand side, we are only losing the exit code of "cat", which we > don't care about. > > (Though I agree that "cat" is pointless here; we could just be > redirecting from a file).
Yep, but an easy mistake to make nonetheless.
> -Peff
Thanks, Taylor