<feed xmlns='http://www.w3.org/2005/Atom'>
<title>git/convert.h, branch v2.16.2</title>
<subtitle>Mirror of https://git.kernel.org/pub/scm/git/git.git/
</subtitle>
<id>https://git.shady.money/git/atom?h=v2.16.2</id>
<link rel='self' href='https://git.shady.money/git/atom?h=v2.16.2'/>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/'/>
<updated>2017-08-27T05:55:05Z</updated>
<entry>
<title>Merge branch 'tb/apply-with-crlf'</title>
<updated>2017-08-27T05:55:05Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2017-08-27T05:55:05Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=a17483fcfe313e9ff5b9b0eb8245605fe7f66ea7'/>
<id>urn:sha1:a17483fcfe313e9ff5b9b0eb8245605fe7f66ea7</id>
<content type='text'>
"git apply" that is used as a better "patch -p1" failed to apply a
taken from a file with CRLF line endings to a file with CRLF line
endings.  The root cause was because it misused convert_to_git()
that tried to do "safe-crlf" processing by looking at the index
entry at the same path, which is a nonsense---in that mode, "apply"
is not working on the data in (or derived from) the index at all.
This has been fixed.

* tb/apply-with-crlf:
  apply: file commited with CRLF should roundtrip diff and apply
  convert: add SAFE_CRLF_KEEP_CRLF
</content>
</entry>
<entry>
<title>convert: add SAFE_CRLF_KEEP_CRLF</title>
<updated>2017-08-16T17:21:17Z</updated>
<author>
<name>Torsten Bögershausen</name>
<email>tboegi@web.de</email>
</author>
<published>2017-08-13T08:51:04Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=2fea9de61857986431982ae89c01c89a2fc10038'/>
<id>urn:sha1:2fea9de61857986431982ae89c01c89a2fc10038</id>
<content type='text'>
When convert_to_git() is called, the caller may want to keep CRLF to
be kept as CRLF (and not converted into LF).

This will be used in the next commit, when apply works with files
that have CRLF and patches are applied onto these files.

Add the new value "SAFE_CRLF_KEEP_CRLF" to safe_crlf.

Prepare convert_to_git() to be able to run the clean filter, skip
the CRLF conversion and run the ident filter.

Signed-off-by: Torsten Bögershausen &lt;tboegi@web.de&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>Merge branch 'ls/filter-process-delayed'</title>
<updated>2017-08-11T20:27:00Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2017-08-11T20:27:00Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=51b8aecabed1363f13c990320a50e1fb2aa3f696'/>
<id>urn:sha1:51b8aecabed1363f13c990320a50e1fb2aa3f696</id>
<content type='text'>
The filter-process interface learned to allow a process with long
latency give a "delayed" response.

* ls/filter-process-delayed:
  convert: add "status=delayed" to filter process protocol
  convert: refactor capabilities negotiation
  convert: move multiple file filter error handling to separate function
  convert: put the flags field before the flag itself for consistent style
  t0021: write "OUT &lt;size&gt;" only on success
  t0021: make debug log file name configurable
  t0021: keep filter log files on comparison
</content>
</entry>
<entry>
<title>convert: add "status=delayed" to filter process protocol</title>
<updated>2017-06-30T20:50:41Z</updated>
<author>
<name>Lars Schneider</name>
<email>larsxschneider@gmail.com</email>
</author>
<published>2017-06-30T20:41:28Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=2841e8f81cb2820024804b9341577be1d0ce1240'/>
<id>urn:sha1:2841e8f81cb2820024804b9341577be1d0ce1240</id>
<content type='text'>
Some `clean` / `smudge` filters may require a significant amount of
time to process a single blob (e.g. the Git LFS smudge filter might
perform network requests). During this process the Git checkout
operation is blocked and Git needs to wait until the filter is done to
continue with the checkout.

Teach the filter process protocol, introduced in edcc8581 ("convert: add
filter.&lt;driver&gt;.process option", 2016-10-16), to accept the status
"delayed" as response to a filter request. Upon this response Git
continues with the checkout operation. After the checkout operation Git
calls "finish_delayed_checkout" which queries the filter for remaining
blobs. If the filter is still working on the completion, then the filter
is expected to block. If the filter has completed all remaining blobs
then an empty response is expected.

Git has a multiple code paths that checkout a blob. Support delayed
checkouts only in `clone` (in unpack-trees.c) and `checkout` operations
for now. The optimization is most effective in these code paths as all
files of the tree are processed.

Signed-off-by: Lars Schneider &lt;larsxschneider@gmail.com&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>convert: convert renormalize_buffer to take an index</title>
<updated>2017-06-13T18:40:51Z</updated>
<author>
<name>Brandon Williams</name>
<email>bmwill@google.com</email>
</author>
<published>2017-06-12T22:13:56Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=a33e0b2a77d7010ba8bf0e025fffaf98f464a938'/>
<id>urn:sha1:a33e0b2a77d7010ba8bf0e025fffaf98f464a938</id>
<content type='text'>
Signed-off-by: Brandon Williams &lt;bmwill@google.com&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>convert: convert convert_to_git to take an index</title>
<updated>2017-06-13T18:40:51Z</updated>
<author>
<name>Brandon Williams</name>
<email>bmwill@google.com</email>
</author>
<published>2017-06-12T22:13:55Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=82b474e025e89cfa294e81611c81355a73dc23a2'/>
<id>urn:sha1:82b474e025e89cfa294e81611c81355a73dc23a2</id>
<content type='text'>
Signed-off-by: Brandon Williams &lt;bmwill@google.com&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>convert: convert convert_to_git_filter_fd to take an index</title>
<updated>2017-06-13T18:40:51Z</updated>
<author>
<name>Brandon Williams</name>
<email>bmwill@google.com</email>
</author>
<published>2017-06-12T22:13:54Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=d6c41c20e688a1b284b92d92320ba56f639688de'/>
<id>urn:sha1:d6c41c20e688a1b284b92d92320ba56f639688de</id>
<content type='text'>
Signed-off-by: Brandon Williams &lt;bmwill@google.com&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>convert: convert get_cached_convert_stats_ascii to take an index</title>
<updated>2017-06-13T18:40:51Z</updated>
<author>
<name>Brandon Williams</name>
<email>bmwill@google.com</email>
</author>
<published>2017-06-12T22:13:52Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=a7609c54b399219bae5b8b94b305cf8e18bf20f8'/>
<id>urn:sha1:a7609c54b399219bae5b8b94b305cf8e18bf20f8</id>
<content type='text'>
Signed-off-by: Brandon Williams &lt;bmwill@google.com&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>convert: unify the "auto" handling of CRLF</title>
<updated>2016-07-06T18:53:51Z</updated>
<author>
<name>Torsten Bögershausen</name>
<email>tboegi@web.de</email>
</author>
<published>2016-06-28T08:01:13Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=6523728499e77afaed0008875b19b308682c3f88'/>
<id>urn:sha1:6523728499e77afaed0008875b19b308682c3f88</id>
<content type='text'>
Before this change,
$ echo "* text=auto" &gt;.gitattributes
$ echo "* eol=crlf" &gt;&gt;.gitattributes

would have the same effect as
$ echo "* text" &gt;.gitattributes
$ git config core.eol crlf

Since the 'eol' attribute had higher priority than 'text=auto', this may
corrupt binary files and is not what most users expect to happen.

Make the 'eol' attribute to obey 'text=auto' and now
$ echo "* text=auto" &gt;.gitattributes
$ echo "* eol=crlf" &gt;&gt;.gitattributes
behaves the same as
$ echo "* text=auto" &gt;.gitattributes
$ git config core.eol crlf

In other words,
$ echo "* text=auto eol=crlf" &gt;.gitattributes
has the same effect as
$ git config core.autocrlf true

and
$ echo "* text=auto eol=lf" &gt;.gitattributes
has the same effect as
$ git config core.autocrlf input

Signed-off-by: Torsten Bögershausen &lt;tboegi@web.de&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>ls-files: add eol diagnostics</title>
<updated>2016-01-19T03:48:43Z</updated>
<author>
<name>Torsten Bögershausen</name>
<email>tboegi@web.de</email>
</author>
<published>2016-01-16T06:50:02Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=a7630bd4274a0dff7cff8b92de3d3f064e321359'/>
<id>urn:sha1:a7630bd4274a0dff7cff8b92de3d3f064e321359</id>
<content type='text'>
When working in a cross-platform environment, a user may want to
check if text files are stored normalized in the repository and
if .gitattributes are set appropriately.

Make it possible to let Git show the line endings in the index and
in the working tree and the effective text/eol attributes.

The end of line ("eolinfo") are shown like this:

    "-text"        binary (or with bare CR) file
    "none"         text file without any EOL
    "lf"           text file with LF
    "crlf"         text file with CRLF
    "mixed"        text file with mixed line endings.

The effective text/eol attribute is one of these:

    "", "-text", "text", "text=auto", "text eol=lf", "text eol=crlf"

git ls-files --eol gives an output like this:

    i/none   w/none   attr/text=auto      t/t5100/empty
    i/-text  w/-text  attr/-text          t/test-binary-2.png
    i/lf     w/lf     attr/text eol=lf    t/t5100/rfc2047-info-0007
    i/lf     w/crlf   attr/text eol=crlf  doit.bat
    i/mixed  w/mixed  attr/               locale/XX.po

to show what eol convention is used in the data in the index ('i'),
and in the working tree ('w'), and what attribute is in effect,
for each path that is shown.

Add test cases in t0027.

Helped-By: Eric Sunshine &lt;sunshine@sunshineco.com&gt;
Signed-off-by: Torsten Bögershausen &lt;tboegi@web.de&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
</feed>
