git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [ANNOUNCE] EasyGit (eg) 0.97

From
Elijah Newren <newren@gmail.com>
Date
Jan 30, 2009, 22:55 UTC
Message-ID
<51419b2c0901301455h32775947rfc4483fd5a5b6c2a@mail.gmail.com>
In-Reply-To
<20090130202917.GA3370@coredump.intra.peff.net>
On Fri, Jan 30, 2009 at 1:29 PM, Jeff King <peff@peff.net> wrote:
Show 6 quoted lines
> If you pass --color on the command line, it is equivalent to "color =
> always" (whereas the default is "auto", which turns it on only if output
> is to a tty).
>
> So you would have to read color.diff yourself and then decide whether to
> add --color.

It looks like I can also set the environment variable GIT_PAGER_IN_USE to achieve the same effects (and I don't even need to do so for most commands, such as diff, just those whose output I'm parsing and possibly tweaking).

Show 7 quoted lines
> Note that in general you are playing things a bit risky with these sorts
> of outputs. You are calling porcelain (like log and status) and piping
> it into your program. There's no guarantee that user config might not be
> affecting the results of those programs.
>
> But I think that is sort of the nature of "eg": to be a thin wrapper
> around git. So maybe it is OK for your use.

Right, I considered switching eg to use git plumbing commands to insulate from issues like this, but the problem is that if git output changes then the eg output really should change too (or else I should have a very specific reason for not changing it). This almost certainly means that I'll have to bump the minimum git version to be used with eg at some point, but that seemed the most reasonable path for eg.

Previous: Jeff KingNext: Jeff King
Message 9 of 10 in “[ANNOUNCE] EasyGit (eg) 0.97”
  1. Elijah NewrenJan 30, 2009
  2. Mike RalphsonJan 30, 2009
  3. Elijah NewrenJan 30, 2009
  4. Jeff KingJan 30, 2009
  5. Jeff KingJan 30, 2009
  6. Elijah NewrenJan 30, 2009
  7. Elijah NewrenJan 30, 2009
  8. Jeff KingJan 30, 2009
  9. Elijah NewrenJan 30, 2009
  10. Jeff KingJan 31, 2009

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.