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

Re: [PATCH] Ignore end-of-line style when computing similarity score for rename detection

From
Junio C Hamano <gitster@pobox.com>
Date
Jun 29, 2007, 06:34 UTC
Message-ID
<7vwsxngtfc.fsf@assigned-by-dhcp.pobox.com>
In-Reply-To
<20070628061821.GM32223@spearce.org>
"Shawn O. Pearce" <spearce@spearce.org> writes:
Show 6 quoted lines
> Actually even better if you can also run the in/out filter things.
> I'm thinking of say an XML file that has had whitespace formatting
> changes, but whose XSD and processors ignore unnecessary whitespace.
> Be nice if the rename detection actually was able to canonicalize
> both files before detecting the rename, assuming both files had a
> canonicalizer input filter defined that does that...

This certainly is tempting, but I suspect that should be left to later rounds. I suspect that it would introduce a concept of two different kinds of diffs, one to be mechanically processed (i.e. use in merge with "git-merge-recursive", and apply with "git-am"), and another to be inspected by humans to understand. It often may be useful to munge the input for the latter case, even though the output from comparing munged input files may not be readily usable for mechanical application.

Which is not a bad thing per-se, but needs to be done carefully.
A replacement set for Steven to comment on follows.
  [PATCH 1/4] diffcore_count_changes: pass diffcore_filespec
  [PATCH 2/4] diffcore_filespec: add is_binary
  [PATCH 3/4] diffcore-delta.c: update the comment on the algorithm.
  [PATCH 4/4] diffcore-delta.c: Ignore CR in CRLF for text files
Previous: Shawn O. PearceNext: Johannes Schindelin
Message 8 of 11 in “Ignore end-of-line style when computing similarity score for rename detection”
  1. Ignore end-of-line style when computing similarity score for rename detectionSteven Grimm, Jun 28, 2007
  2. Ignore end-of-line style when computing similarity score for rename detectionSteven Grimm, Jun 28, 2007
  3. Johannes SixtJun 28, 2007
  4. Junio C HamanoJun 28, 2007
  5. Junio C HamanoJun 28, 2007
  6. Ignore end-of-line style when computing similarity score for rename detectionSteven Grimm, Jun 28, 2007
  7. Shawn O. PearceJun 28, 2007
  8. Junio C HamanoJun 29, 2007
  9. Johannes SchindelinJun 28, 2007
  10. Steven GrimmJun 28, 2007
  11. Johannes SchindelinJun 29, 2007

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.