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

git commit <path> scanning entire working tree?

From
Sskillzero@gmail.com <skillzero@gmail.com>
Date
Feb 16, 2009, 22:58 UTC
Message-ID
<2729632a0902161458m732af362od59e5f35af5643c3@mail.gmail.com>

When I do a 'git commit <path to a single file>', git seems to scan the entire working tree. Since my tree is relatively large (and when on Windows, stat'ing is even slower), it takes quite a while (5 or so seconds) before I can even edit the commit message.

Is there a reason it needs to scan like this when the commit command specifies a specific path? It seems like it would only need to scan the path I've specified.

Next: Junio C Hamano
Message 1 of 7 in “git commit <path> scanning entire working tree?”
  1. skillzero@gmail.comFeb 16, 2009
  2. Junio C HamanoFeb 17, 2009
  3. Boyd Stephen Smith Jr.Feb 17, 2009
  4. skillzero@gmail.comFeb 17, 2009
  5. Boyd Stephen Smith Jr.Feb 17, 2009
  6. Junio C HamanoFeb 17, 2009
  7. skillzero@gmail.comFeb 18, 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.