]> git.proxmox.com Git - libgit2.git/commit - src/util/futils.c
Implement filters for status/diff blobs
authorRussell Belfer <rb@github.com>
Wed, 5 Sep 2012 22:00:40 +0000 (15:00 -0700)
committerRussell Belfer <rb@github.com>
Thu, 6 Sep 2012 22:34:02 +0000 (15:34 -0700)
commit60b9d3fcef04a6beb0ad4df225ada058afabf0b9
treeefc9e427753619d29d1df56b0ea97446f1a3f9d9
parent8f9b6a132b358b23b518197240184e2f08e0a913
Implement filters for status/diff blobs

This adds support to diff and status for running filters (a la crlf)
on blobs in the workdir before computing SHAs and before generating
text diffs.  This ended up being a bit more code change than I had
thought since I had to reorganize some of the diff logic to minimize
peak memory use when filtering blobs in a diff.

This also adds a cap on the maximum size of data that will be loaded
to diff.  I set it at 512Mb which should match core git.  Right now
it is a #define in src/diff.h but it could be moved into the public
API if desired.
src/diff.c
src/diff.h
src/diff_output.c
src/fileops.c
src/fileops.h
src/odb.c
src/odb.h
tests-clar/status/worktree.c