summaryrefslogtreecommitdiff
path: root/include/git2/checkout.h
diff options
context:
space:
mode:
authorEdward Thomson <ethomson@microsoft.com>2013-12-12 11:30:50 -0500
committerEdward Thomson <ethomson@microsoft.com>2013-12-13 09:29:55 -0500
commit81a2012d991212fbbbf98bf7eefca3dc5d0fd7bb (patch)
tree63a0321d37ab381ed8e9db874fc1b0a319d09f3f /include/git2/checkout.h
parent79194bcdc956406979cd27ac99198826860d3f20 (diff)
downloadlibgit2-81a2012d991212fbbbf98bf7eefca3dc5d0fd7bb.tar.gz
Overwrite ignored files on checkout
Diffstat (limited to 'include/git2/checkout.h')
-rw-r--r--include/git2/checkout.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/include/git2/checkout.h b/include/git2/checkout.h
index 0e9d338c6..b94a5e2ff 100644
--- a/include/git2/checkout.h
+++ b/include/git2/checkout.h
@@ -99,6 +99,11 @@ GIT_BEGIN_DECL
* files with unmerged index entries instead. GIT_CHECKOUT_USE_OURS and
* GIT_CHECKOUT_USE_THEIRS to proceed with the checkout using either the
* stage 2 ("ours") or stage 3 ("theirs") version of files in the index.
+ *
+ * - GIT_CHECKOUT_DONT_OVERWRITE_IGNORED prevents ignored files from being
+ * overwritten. Normally, files that are ignored in the working directory
+ * are not considered "precious" and may be overwritten if the checkout
+ * target contains that file.
*/
typedef enum {
GIT_CHECKOUT_NONE = 0, /** default is a dry run, no actual updates */
@@ -144,6 +149,9 @@ typedef enum {
/** Ignore directories in use, they will be left empty */
GIT_CHECKOUT_SKIP_LOCKED_DIRECTORIES = (1u << 18),
+ /** Don't overwrite ignored files that exist in the checkout target */
+ GIT_CHECKOUT_DONT_OVERWRITE_IGNORED = (1u << 19),
+
/**
* THE FOLLOWING OPTIONS ARE NOT YET IMPLEMENTED
*/