summaryrefslogtreecommitdiff
path: root/include/git2/status.h
diff options
context:
space:
mode:
authorRussell Belfer <rb@github.com>2013-03-25 22:19:39 -0700
committerRussell Belfer <rb@github.com>2013-03-25 22:19:39 -0700
commit37ee70fab4e6dcf35afc08c0edbe9f101d4abf2d (patch)
treee9bee47b3059bbc5189e0833b927a3bf50776bdf /include/git2/status.h
parent0c289dd7c6831f4f402f9581b46d0c920053abf9 (diff)
downloadlibgit2-37ee70fab4e6dcf35afc08c0edbe9f101d4abf2d.tar.gz
Implement GIT_STATUS_OPT_EXCLUDE_SUBMODULES
This option has been sitting unimplemented for a while, so I finally went through and implemented it along with some tests. As part of this, I improved the implementation of GIT_DIFF_IGNORE_SUBMODULES so it be more diligent about avoiding extra work and about leaving off delta records for submodules to the greatest extent possible (though it may include them still if you are request TYPECHANGE records).
Diffstat (limited to 'include/git2/status.h')
-rw-r--r--include/git2/status.h8
1 files changed, 7 insertions, 1 deletions
diff --git a/include/git2/status.h b/include/git2/status.h
index fa6282090..38b6fa5bd 100644
--- a/include/git2/status.h
+++ b/include/git2/status.h
@@ -133,7 +133,8 @@ typedef enum {
*
* Calling `git_status_foreach()` is like calling the extended version
* with: GIT_STATUS_OPT_INCLUDE_IGNORED, GIT_STATUS_OPT_INCLUDE_UNTRACKED,
- * and GIT_STATUS_OPT_RECURSE_UNTRACKED_DIRS.
+ * and GIT_STATUS_OPT_RECURSE_UNTRACKED_DIRS. Those options are bundled
+ * together as `GIT_STATUS_OPT_DEFAULTS` if you want them as a baseline.
*/
typedef enum {
GIT_STATUS_OPT_INCLUDE_UNTRACKED = (1u << 0),
@@ -145,6 +146,11 @@ typedef enum {
GIT_STATUS_OPT_RECURSE_IGNORED_DIRS = (1u << 6),
} git_status_opt_t;
+#define GIT_STATUS_OPT_DEFAULTS \
+ (GIT_STATUS_OPT_INCLUDE_IGNORED | \
+ GIT_STATUS_OPT_INCLUDE_UNTRACKED | \
+ GIT_STATUS_OPT_RECURSE_UNTRACKED_DIRS)
+
/**
* Options to control how `git_status_foreach_ext()` will issue callbacks.
*