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

git config --help not functional on bad config

From
Peter Krefting <peter@softwolves.pp.se>
Date
Jul 11, 2017, 14:49 UTC
Message-ID
<alpine.DEB.2.00.1707111541150.18163@ds9.cixit.se>
So, I set the wrong value for a configuration option, and git tells me:
   $ git config branch.autoSetupRebase false
   $ git log
   error: malformed value for branch.autosetuprebase
   fatal: bad config variable 'branch.autosetuprebase' in file '.git/config' at line 24

That's fine. However, when trying to look for help, it is not that useful:

   $ git config --help
   error: malformed value for branch.autosetuprebase
   fatal: bad config variable 'branch.autosetuprebase' in file '.git/config' at line 24

Perhaps it should allow "--help" to go through even if the configuration is bad?

After a "git config --unset branch.autosetuprebase" everything works again, but I had to look that up manually calling "man git-config" (afterwards I realized I could go out of the repo to be unaffected by the config, but that probably wouldn't have helped if I had put this in my global config).

-- 
\\// Peter - http://www.softwolves.pp.se/
Next: Jeff King
Message 1 of 6 in “git config --help not functional on bad config”
  1. Peter KreftingJul 11, 2017
  2. Jeff KingJul 11, 2017
  3. Stefan BellerJul 11, 2017
  4. Jeff KingJul 11, 2017
  5. Stefan BellerJul 11, 2017
  6. Jeff KingJul 11, 2017

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.