Re: [PATCH v2] diff: support anchoring line(s)

2017-11-27 Thread Junio C Hamano
Jonathan Tan writes: > - else if (!strcmp(arg, "--patience")) > + else if (!strcmp(arg, "--patience")) { > + int i; > options->xdl_opts = DIFF_WITH_ALG(options, PATIENCE_DIFF); > - else if (!strcmp(arg, "--histogram")) > +

[PATCH v2] diff: support anchoring line(s)

2017-11-27 Thread Jonathan Tan
Teach diff a new algorithm, one that attempts to prevent user-specified lines from appearing as a deletion or addition in the end result. The end user can use this by specifying "--anchored=" one or more times when using Git commands like "diff" and "show". Signed-off-by: Jonathan Tan