diff options
author | yorah <yoram.harmelin@gmail.com> | 2013-01-25 17:35:46 +0100 |
---|---|---|
committer | yorah <yoram.harmelin@gmail.com> | 2013-02-07 20:44:35 +0100 |
commit | 0d64ba48372f95ade17a27f1b11620638ca52d61 (patch) | |
tree | c713abaeb7e3629e221c09f4c9338e0878006e98 /tests-clar/diff/diff_helpers.h | |
parent | 943700ecbbc2be4ef49c5c31d8e5c49353fd3d84 (diff) | |
download | libgit2-0d64ba48372f95ade17a27f1b11620638ca52d61.tar.gz |
diff: add a notify callback to `git_diff__from_iterators`
The callback will be called for each file, just before the `git_delta_t` gets inserted into the diff list.
When the callback:
- returns < 0, the diff process will be aborted
- returns > 0, the delta will not be inserted into the diff list, but the diff process continues
- returns 0, the delta is inserted into the diff list, and the diff process continues
Diffstat (limited to 'tests-clar/diff/diff_helpers.h')
-rw-r--r-- | tests-clar/diff/diff_helpers.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/tests-clar/diff/diff_helpers.h b/tests-clar/diff/diff_helpers.h index 49c265285..a43847b79 100644 --- a/tests-clar/diff/diff_helpers.h +++ b/tests-clar/diff/diff_helpers.h @@ -20,6 +20,11 @@ typedef struct { int line_dels; } diff_expects; +typedef struct { + const char *path; + const char *matched_pathspec; +} notify_expected; + extern int diff_file_cb( const git_diff_delta *delta, float progress, |