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

git-add has gone lstat() mad

From
APAndy Parkins <andyparkins@gmail.com>
Date
Mar 30, 2007, 19:55 UTC
Message-ID
<200703302055.13619.andyparkins@gmail.com>
Hello,

I was interested in trying out the GIT_WORK_DIR stuff, but ended up being unable to. The thing that stopped me is present in master as well:

 $ git --version
 git version 1.5.1.rc3.20.gaa453
 $ cd $HOME
 $ git init
 $ git add .bashrc

At this point the CPU pegs at 100% systime. An strace shows that git is calling lstat64() on every file in my home directory. I killed git before it scanned everything I've ever done.

I only want to track one file; is git meant to scan every file in the directory even though I'm not adding any of them?

Andy
-- 
Dr Andy Parkins, M Eng (hons), MIET
andyparkins@gmail.com
Next: Andy Parkins
Message 1 of 10 in “git-add has gone lstat() mad”
  1. Andy ParkinsMar 30, 2007
  2. Andy ParkinsMar 30, 2007
  3. Junio C HamanoMar 31, 2007
  4. Linus TorvaldsMar 31, 2007
  5. Andy ParkinsMar 31, 2007
  6. Randal L. SchwartzMar 31, 2007
  7. Andy ParkinsMar 31, 2007
  8. Tom PrinceMar 31, 2007
  9. Junio C HamanoApr 1, 2007
  10. Andy ParkinsApr 1, 2007

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.