On Tue, 21 Oct 2025, Peter0x44 wrote: > Oct 21, 2025 6:00:49 PM Joseph Myers <[email protected]>: > > > On Tue, 21 Oct 2025, Peter Damianov wrote: > > > >> +/* This comment has CRLF line endings > >> + and should appear as two lines in the output, not three. */ > > > > Since email does not preserve the presence of CRLF line endings, I'm not > > sure (a) what form of line endings you intend to be present in the blob > > object for the file in the repository (as opposed to in the checked out > > file in a working tree), and (b) what the intended process is for applying > > the patch to result in both correct line endings in the blob pointed to by > > the tree pointed to by the commit, and in the working copy where the patch > > was applied. > > I'm not certain what the process should be. I figured telling git to use > crlf in the gitattributes was enough. The intent is that the test file > is always saved with crlf.
My inclination is that telling git to treat it as not a text file (and providing it as a binary file with the diff) may be preferable to telling git to do something involving line ending conversions. -- Joseph S. Myers [email protected]
