summaryrefslogtreecommitdiff
path: root/dir.h
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2017-06-02 06:06:04 (GMT)
committerJunio C Hamano <gitster@pobox.com>2017-06-02 06:06:05 (GMT)
commitf4fd99bf6e5c27265ee2a9ccb9c2495854f67acb (patch)
tree2fae59f74c523e7e58465b24aa343b4a90debc46 /dir.h
parentd027b467fcb526433902b024a5d30844d9346e57 (diff)
parent6b1db43109ab3d4c92e61874cd149779c66016db (diff)
downloadgit-f4fd99bf6e5c27265ee2a9ccb9c2495854f67acb.zip
git-f4fd99bf6e5c27265ee2a9ccb9c2495854f67acb.tar.gz
git-f4fd99bf6e5c27265ee2a9ccb9c2495854f67acb.tar.bz2
Merge branch 'sl/clean-d-ignored-fix'
"git clean -d" used to clean directories that has ignored files, even though the command should not lose ignored ones without "-x". "git status --ignored" did not list ignored and untracked files without "-uall". These have been corrected. * sl/clean-d-ignored-fix: clean: teach clean -d to preserve ignored paths dir: expose cmp_name() and check_contains() dir: hide untracked contents of untracked dirs dir: recurse into untracked dirs for ignored files t7061: status --ignored should search untracked dirs t7300: clean -d should skip dirs with ignored files
Diffstat (limited to 'dir.h')
-rw-r--r--dir.h6
1 files changed, 5 insertions, 1 deletions
diff --git a/dir.h b/dir.h
index 17d1106..a89c13e 100644
--- a/dir.h
+++ b/dir.h
@@ -151,7 +151,8 @@ struct dir_struct {
DIR_NO_GITLINKS = 1<<3,
DIR_COLLECT_IGNORED = 1<<4,
DIR_SHOW_IGNORED_TOO = 1<<5,
- DIR_COLLECT_KILLED_ONLY = 1<<6
+ DIR_COLLECT_KILLED_ONLY = 1<<6,
+ DIR_KEEP_UNTRACKED_CONTENTS = 1<<7
} flags;
struct dir_entry **entries;
struct dir_entry **ignored;
@@ -337,6 +338,9 @@ static inline int dir_path_match(const struct dir_entry *ent,
has_trailing_dir);
}
+int cmp_dir_entry(const void *p1, const void *p2);
+int check_dir_entry_contains(const struct dir_entry *out, const struct dir_entry *in);
+
void untracked_cache_invalidate_path(struct index_state *, const char *);
void untracked_cache_remove_from_index(struct index_state *, const char *);
void untracked_cache_add_to_index(struct index_state *, const char *);