diff options
author | Junio C Hamano <gitster@pobox.com> | 2014-03-18 13:58:58 -0700 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2014-03-18 13:58:58 -0700 |
commit | 6a0556e4c0d0174d4c1760469e0f4d348b5ca844 (patch) | |
tree | 7d4d03f407db1fa352021dd9f843d57e52a28d9a /resolve-undo.c | |
parent | 16216b6ab1073b7aaa8225c32208758e6ea16629 (diff) | |
parent | 2e70c01799bf663cc1fa5f6e37e025000ffdc0b0 (diff) | |
download | git-6a0556e4c0d0174d4c1760469e0f4d348b5ca844.tar.gz git-6a0556e4c0d0174d4c1760469e0f4d348b5ca844.tar.xz |
Merge branch 'nd/submodule-pathspec-ending-with-slash' into maint
Allow "git cmd path/", when the 'path' is where a submodule is
bound to the top-level working tree, to match 'path', despite the
extra and unnecessary trailing slash (such a slash is often
given by command line completion).
* nd/submodule-pathspec-ending-with-slash:
clean: use cache_name_is_other()
clean: replace match_pathspec() with dir_path_match()
pathspec: pass directory indicator to match_pathspec_item()
match_pathspec: match pathspec "foo/" against directory "foo"
dir.c: prepare match_pathspec_item for taking more flags
pathspec: rename match_pathspec_depth() to match_pathspec()
pathspec: convert some match_pathspec_depth() to dir_path_match()
pathspec: convert some match_pathspec_depth() to ce_path_match()
Diffstat (limited to 'resolve-undo.c')
-rw-r--r-- | resolve-undo.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/resolve-undo.c b/resolve-undo.c index c09b00664..67d154314 100644 --- a/resolve-undo.c +++ b/resolve-undo.c @@ -182,7 +182,7 @@ void unmerge_index(struct index_state *istate, const struct pathspec *pathspec) for (i = 0; i < istate->cache_nr; i++) { const struct cache_entry *ce = istate->cache[i]; - if (!match_pathspec_depth(pathspec, ce->name, ce_namelen(ce), 0, NULL)) + if (!ce_path_match(ce, pathspec, NULL)) continue; i = unmerge_index_entry_at(istate, i); } |