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

[user confusion] git-config error messages

From
IMIngo Molnar <mingo@elte.hu>
Date
May 12, 2008, 14:16 UTC
Message-ID
<20080512141636.GA29590@elte.hu>

ok, i thought i'd share this stupid little episode of user error. I wanted to enable git-rerere:

 $ git-config --add rerere.enabled true
 could not lock config file
 #
 # Hm, do remember this option incorrectly? And what lock file?
 #
 $ git-config --add rerere.enabled=1
 key does not contain a section: --add
 #
 # What section? What key?
 #
 $ git-config --add rerere.enabled=true
 key does not contain a section: --add
 #
 # Huh? Ok, lets try strace:
 #
 $ strace -f git-config --add rerere.enabled true 2>&1 | grep \\.lock
 open(".git/config.lock", O_RDWR|O_CREAT|O_EXCL|O_LARGEFILE, 0666) = -1 ENOENT (No such file or directory)
 #
 # Ah, stupid me! I forgot to cd into the Git repository and it tries to 
 # access .git. And i wanted the --global option anyway. So the Git 
 # error messages led me on the completely wrong path.
 #
Next: Alex Riesen
Message 1 of 3 in “[user confusion] git-config error messages”
  1. Ingo MolnarMay 12, 2008
  2. Improve reporting of errors in config file routinesAlex Riesen, May 12, 2008
  3. Junio C HamanoMay 12, 2008

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.