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

Re: auto commit merge using the default merge message

From
Brian Gernhardt <benji@silverinsanity.com>
Date
Apr 23, 2009, 16:19 UTC
Message-ID
<CA5A92BB-29E5-40C0-BA9A-ED076676D8BF@silverinsanity.com>
In-Reply-To
<49F02FC0.1010007@drmicha.warpmail.net>
On Apr 23, 2009, at 5:07 AM, Michael J Gruber wrote:
Show 13 quoted lines
> Junio C Hamano venit, vidit, dixit 23.04.2009 10:32:
>> Use "GIT_EDITOR=:" instead.  It also is *true* just like /bin/true,
>> but git knows a simple magic about this and avoids an extra
>> fork+exec.
>
> Good to know!
>
>> A similar trick exists for GIT_PAGER=cat (not "/bin/cat"), by the
>> way.
>>
>
> So, GIT_PAGER=cat differs from GIT_PAGER=/bin/cat even when `which
> cat`==/bin/cat?

Yes, if $GIT_PAGER == "cat", then git won't launch a pager at all. If $GIT_PAGER == "/bin/cat", then git will launch /bin/cat and pipe all of it's output through it. The result is (assuming a functional /bin/ cat) identical, but "cat" avoids the extra memory usage of "/bin/cat".

~~ Brian
Previous: Michael J GruberNext: Caleb Cushing
Message 6 of 10 in “auto commit merge using the default merge message”
  1. Caleb CushingApr 23, 2009
  2. Alex RiesenApr 23, 2009
  3. Michael J GruberApr 23, 2009
  4. Junio C HamanoApr 23, 2009
  5. Michael J GruberApr 23, 2009
  6. Brian GernhardtApr 23, 2009
  7. Caleb CushingApr 24, 2009
  8. Jeff KingApr 24, 2009
  9. Caleb CushingApr 24, 2009
  10. Jeff KingApr 24, 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.