match_pathspec() -- return how well the spec matched
authorJunio C Hamano <junkio@cox.net>
Mon, 25 Dec 2006 11:09:52 +0000 (03:09 -0800)
committerJunio C Hamano <junkio@cox.net>
Mon, 25 Dec 2006 11:29:08 +0000 (03:29 -0800)
This updates the return value from match_pathspec() so that the
caller can tell cases between exact match, leading pathname
match (i.e. file "foo/bar" matches a pathspec "foo"), or
filename glob match. This can be used to prevent "rm dir" from
removing "dir/file" without explicitly asking for recursive
behaviour with -r flag, for example.

Signed-off-by: Junio C Hamano <junkio@cox.net>
No differences found