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

[PATCH v4 0/1] docs: rewrite the documentation of the text and eol attributes

From
Alex Henrie <alexhenrie24@gmail.com>
Date
May 3, 2023, 04:46 UTC
Message-ID
<20230503044656.221175-1-alexhenrie24@gmail.com>
In-Reply-To
<20230501023533.35370-1-alexhenrie24@gmail.com>
Changes from v3:
- Rewrite sentence about how `eol` can imply `text`
- Use the phrase "all other platforms" instead of the word "Unix"
Alex Henrie (1):
  docs: rewrite the documentation of the text and eol attributes
 Documentation/gitattributes.txt | 59 +++++++++++++++++----------------
 1 file changed, 31 insertions(+), 28 deletions(-)
Range-diff against v3:
1:  3d5985bc28 ! 1:  eccf627db1 docs: rewrite the documentation of the text and eol attributes
    @@ Commit message
         does not do anything to the line endings either.
     
         On top of that, in several places the documentation for the eol
    -    attribute sounds like it can turn on normalization on checkin, but eol
    -    only controls conversion on checkout. It also sounds like setting eol
    +    attribute sounds like either it does not affect normalization on checkin
    +    or it forces normalization on checkin. It also sounds like setting eol
         (or setting a config variable) is required to turn on conversion on
         checkout, but the text attribute can turn on conversion on checkout by
         itself if eol is unspecified.
    @@ Documentation/gitattributes.txt: unspecified.
     -`text=auto` is set. Adding the path to the index again will normalize
     -the line endings in the index.
     +This attribute marks a path to use a specific line-ending style in the
    -+working tree when it is checked out.  This attribute has effect only if
    -+the `text` attribute is set or unspecified, or if it is set to `auto`,
    -+the file is detected as text, and it is stored with LF endings in the
    -+index.
    ++working tree when it is checked out.  It has effect only if `text` or
    ++`text=auto` is set (see above), but specifying `eol` automatically sets
    ++`text` if `text` was left unspecified.
      
      Set to string value "crlf"::
      
    @@ Documentation/gitattributes.txt: unspecified.
     +	If the `eol` attribute is unspecified for a file, its line endings
     +	in the working directory are determined by the `core.autocrlf` or
     +	`core.eol` configuration variable (see the definitions of those
    -+	options in linkgit:git-config[1]).  The default if `text` is set but
    -+	neither of those variables is is `eol=lf` on Unix and `eol=crlf` on
    -+	Windows.
    ++	options in linkgit:git-config[1]).  If `text` is set but neither of
    ++	those variables is, the default is `eol=crlf` on Windows and
    ++	`eol=lf` on all other platforms.
      
      Backwards compatibility with `crlf` attribute
      ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
-- 
2.40.1
Previous: Felipe ContrerasNext: Alex Henrie
Message 6 of 10 in “docs: rewrite the documentation of the text and eol attributes”
  1. 0/1 docs: rewrite the documentation of the text and eol attributesAlex Henrie, May 1, 2023
  2. 1/1 docs: rewrite the documentation of the text and eol attributesAlex Henrie, May 1, 2023
  3. Torsten BögershausenMay 2, 2023
  4. Alex HenrieMay 2, 2023
  5. Felipe ContrerasMay 2, 2023
  6. 0/1 docs: rewrite the documentation of the text and eol attributesAlex Henrie, May 3, 2023
  7. 1/1 docs: rewrite the documentation of the text and eol attributesAlex Henrie, May 3, 2023
  8. Junio C HamanoMay 3, 2023
  9. Torsten BögershausenMay 3, 2023
  10. Junio C HamanoMay 3, 2023

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.