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

Re: [PATCH] convert: clarify line ending conversion warning

From
Ævar Arnfjörð Bjarmason <avarab@gmail.com>
Date
Apr 4, 2022, 06:06 UTC
Message-ID
<220404.867d85l6ok.gmgdl@evledraar.gmail.com>
In-Reply-To
<20220404055151.160184-1-alexhenrie24@gmail.com>
On Sun, Apr 03 2022, Alex Henrie wrote:
Show 17 quoted lines
> The warning about converting line endings is extremely confusing. Its
> two sentences each use the word "will" without specifying a timeframe,
> which makes it sound like both sentences are referring to the same
> timeframe. On top of that, it uses the term "original line endings"
> without saying whether "original" means LF or CRLF.
>
> Rephrase the warning to be clear that line endings have not been changed
> in the working directory but will be changed on the next checkout, and
> explicitly say which line endings the file currently has in the working
> directory.
>
> Example commands to trigger the warning on Linux:
>
> git config core.autocrlf true
> echo 'Hello world!' > hello.txt
> git add hello.txt
> git commit -m "Add hello.txt"

Just eyeballing this, while there might be some improvements here one thing to consider is atht now %s isn't at the end of the line.

It's fine for hello.txt, but consider longer paths, before:
	LF will be replaced by CRLF in /home/hello/hello/hello/hello/hello/hello/hello/hello/hello/hello/hello/hello/hello/hello/hello/hello/hello/hello/hello/hello/hello/hello/hello/hello/hello/hello/hello/hello.txt.
V.s.:
	LF will be replaced by CRLF in /home/hello/hello/hello/hello/hello/hello/hello/hello/hello/hello/hello/hello/hello/hello/hello/hello/hello/hello/hello/hello/hello/hello/hello/hello/hello/hello/hello/hello.txt the next time you check it out.
Previous: Alex HenrieNext: Tao Klerks
Message 2 of 8 in “convert: clarify line ending conversion warning”
  1. convert: clarify line ending conversion warningAlex Henrie, Apr 4, 2022
  2. Ævar Arnfjörð BjarmasonApr 4, 2022
  3. Tao KlerksApr 4, 2022
  4. Alex HenrieApr 4, 2022
  5. Tao KlerksApr 5, 2022
  6. Junio C HamanoApr 4, 2022
  7. Alex HenrieApr 4, 2022
  8. Junio C HamanoApr 4, 2022

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.