Re: [RFC] column: show auto columns when pager is active
- From
Jeff King <peff@peff.net>
- Date
- Oct 10, 2017, 14:10 UTC
- Message-ID
- <20171010141019.3vfowj4fvxdvvl3c@sigill.intra.peff.net>
- In-Reply-To
- <20171009214543.12986-1-me@ikke.info>
On Mon, Oct 09, 2017 at 11:45:43PM +0200, Kevin Daudt wrote:
Show 12 quoted lines
> +test_expect_success TTY '20 columns, mode auto, pager' ' > + cat >expected <<\EOF && > +one seven > +two eight > +three nine > +four ten > +five eleven > +six > +EOF > + test_terminal env PAGER="cat|cat" git column --mode=auto <lista >actual && > + test_cmp expected actual > +'
I don't think "git column" will run the pager by default, will it? You'd need "git -p" here.
That said, I'm still puzzled why it would return zero output. Strace shows that the read from stdin is getting no input. I suspect this may have to do with how we redirect stdin in test-terminal.perl.
See 18d8c26930 (test_terminal: redirect child process' stdin to a pty, 2015-08-04), which claims there's some raciness with closing the descriptor.
-Peff