From: Kristoffer Haugsbakk Date: Thu, 11 Sep 2025 16:49:20 GMT Subject: Re: [PATCH 5/5] builtin/config: do not spawn pager when printing color codes Message-ID: In-Reply-To: <20250911-pks-config-color-v1-5-3a7c79df65b1@pks.im> On Thu, Sep 11, 2025, at 15:24, Patrick Steinhardt wrote: > With `git config get --type=color` the user asks us to parse a specific > configuration key and turn the value into an ANSI color escape sequence. > The printed string can then for example be used as part of shell scripts > to reuse the same colors as Git. > > Right now though we set up the auto-pager though, which means that the Double “though”. > string may instead be written to the pager command. This is of course > quite nonsensical: there shouldn't be any use case where the color code IMO s/:/;/ s/use case/use-case/ > should end up in the pager instead of in the TTY. > > Fix this by disabling the pager in case the user is asking us to print > color sequences. > > Signed-off-by: Patrick Steinhardt >[snip the diff]