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

Re: CRLF behavior

From
Avery Pennarun <apenwarr@gmail.com>
Date
Jul 21, 2010, 21:51 UTC
Message-ID
<AANLkTinyTlrkALbfVqdqzr_O4ClN-JGS9zsYwH1Upe1v@mail.gmail.com>
In-Reply-To
<1A9EA7E081C3FE46A0F446FFB66D10EB9398FF@FL01EXMB01.trad.tradestation.com>
On Wed, Jul 21, 2010 at 5:35 PM, John Dlugosz <JDlugosz@tradestation.com> wrote:
Show 6 quoted lines
>> > Running git config --list shows nothing that would suggest any such
>> setting.
>>
>> Try 'git config --global --list'
>
> I thought that --list tells me the sum result of all the settings in force; i.e. the final result that should be used here and now.
Sadly not.
>> Try 'git config --global --list'
>
> I get:  fatal: $HOME not set
Yow, that's kind of bad news.  It implies that if you run git from one
shell, it will be able to find your global .gitconfig (and thus use
autocrlf), but if you run it from a different kind of shell, it won't.
 This could be the root of your problem.

One "solution" would be to change git to always die immediately if $HOME isn't set.

> So, assuming it's been that way (the file is dated March), what's the repository "really"
> doing?  When things started acting funny, my co-worker found this setting and removed
> it from his.  If that's not it, I can only wonder why it started showing all-lines-changed ?

I don't know. One thing I do know is that changing the autocrlf setting on an active repository makes git go bonkers and there's no (as far as I know) well-documented way to un-bonkers it other than to just check out everything again.

If your problem really is that the ~/.gitconfig comes and goes (as far as git is concerned), it could certainly have caused this problem.

Have fun,
Avery
Previous: John DlugoszNext: Avery Pennarun
Message 4 of 9 in “CRLF behavior”
  1. John DlugoszJul 21, 2010
  2. Avery PennarunJul 21, 2010
  3. John DlugoszJul 21, 2010
  4. Avery PennarunJul 21, 2010
  5. Avery PennarunJul 21, 2010
  6. John DlugoszJul 21, 2010
  7. John DlugoszJul 21, 2010
  8. Finn Arne GangstadJul 26, 2010
  9. John DlugoszJul 26, 2010

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.