summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
Diffstat (limited to 'include')
-rw-r--r--include/git2/checkout.h15
1 files changed, 15 insertions, 0 deletions
diff --git a/include/git2/checkout.h b/include/git2/checkout.h
index 42d47003d..ef3badbe9 100644
--- a/include/git2/checkout.h
+++ b/include/git2/checkout.h
@@ -36,6 +36,21 @@ typedef struct git_checkout_opts {
int file_mode; /* default is 0644 */
int file_open_flags; /* default is O_CREAT | O_TRUNC | O_WRONLY */
+ /* Optional callback to notify the consumer of files that
+ * haven't be checked out because a modified version of them
+ * exist in the working directory.
+ *
+ * When provided, this callback will be invoked when the flag
+ * GIT_CHECKOUT_OVERWRITE_MODIFIED isn't part of the checkout strategy.
+ */
+ int (* skipped_notify_cb)(
+ const char *skipped_file,
+ const git_oid *blob_oid,
+ int file_mode,
+ void *payload);
+
+ void *notify_payload;
+
/* when not NULL, arrays of fnmatch pattern specifying
* which paths should be taken into account
*/