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

[Q] Where does "git commit -q -m msg" spend time?

From
Junio C Hamano <gitster@pobox.com>
Date
Nov 18, 2022, 23:37 UTC
Message-ID
<xmqqbkp3kf5y.fsf@gitster.g>

On a slow filesystem it gets more noticeable, but I have been wondering (without a debugger or a profiler, as I am supposed to be on vacation) for the past few weeks why these two commands in the same repository perform very differently:

    $ git write-tree
    $ git commit -q -m msg

Especially even after running the former, running the latter, which I naïvely thought that it only needs to create a commit object with "msg" and wrapping the result of the former (which is more-or-less instant) into it, and do nothing else.

Message 1 of 1 in “[Q] Where does "git commit -q -m msg" spend time?”
  1. Junio C HamanoNov 18, 2022

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.