libgit2/tests-clar/diff
Russell Belfer 74ded02457 Add "as_path" parameters to blob and buffer diffs
This adds parameters to the four functions that allow for blob-to-
blob and blob-to-buffer differencing (either via callbacks or by
making a git_diff_patch object).  These parameters let you say
that filename we should pretend the blob has while doing the diff.
If you pass NULL, there should be no change from the existing
behavior, which is to skip using attributes for file type checks
and just look at content.  With the parameters, you can plug into
the new diff driver functionality and get binary or non-binary
behavior, plus function context regular expressions, etc.

This commit also fixes things so that the git_diff_delta that is
generated by these functions will actually be populated with the
data that we know about the blobs (or buffers) so you can use it
appropriately.  It also fixes a bug in generating patches from
the git_diff_patch objects created via these functions.

Lastly, there is one other behavior change that may matter.  If
there is no difference between the two blobs, these functions no
longer generate any diff callbacks / patches unless you have
passed in GIT_DIFF_INCLUDE_UNMODIFIED.  This is pretty natural,
but could potentially change the behavior of existing usage.
2013-06-17 17:03:34 -07:00
..
blob.c Add "as_path" parameters to blob and buffer diffs 2013-06-17 17:03:34 -07:00
diff_helpers.c More diff rename tests; better split swap handling 2013-05-23 15:06:07 -07:00
diff_helpers.h More diff rename tests; better split swap handling 2013-05-23 15:06:07 -07:00
diffiter.c Replace diff delta binary with flags 2013-02-20 15:10:21 -08:00
drivers.c Fix some diff driver memory leaks 2013-06-12 11:54:11 -07:00
index.c Fix some leaks and (possibly) dangling pointers in tests 2012-12-19 08:04:31 +01:00
iterator.c Make iterators use GIT_ITEROVER & smart advance 2013-05-31 12:18:43 -07:00
notify.c Notify '*' pathspec correctly when diffing 2013-04-11 09:59:26 +02:00
patch.c Implement regex pattern diff driver 2013-06-11 11:22:22 -07:00
rename.c Fix memory leaks in diff rename tests 2013-06-17 10:03:50 -07:00
submodules.c Reorganize diff and add basic diff driver 2013-06-10 10:10:39 -07:00
tree.c Improve diff config options handling 2013-04-23 12:57:30 -07:00
workdir.c Fix diff crash when last item is untracked dir 2013-05-15 14:50:05 -07:00