Re: [PATCH 3/4] dir.c: support marking some patterns already matched

2016-02-15 Thread Duy Nguyen
On Tue, Feb 16, 2016 at 6:47 AM, Junio C Hamano wrote: > Nguyễn Thái Ngọc Duy writes: > >> Given path "a" and the pattern "a", it's matched. But if we throw path >> "a/b" to pattern "a", the code fails to realize that if "a" matches >> "a" then "a/b" should also be matched. >> >> When the patter

Re: [PATCH 3/4] dir.c: support marking some patterns already matched

2016-02-15 Thread Junio C Hamano
Nguyễn Thái Ngọc Duy writes: > Given path "a" and the pattern "a", it's matched. But if we throw path > "a/b" to pattern "a", the code fails to realize that if "a" matches > "a" then "a/b" should also be matched. > > When the pattern is matched the first time, we can mark it "sticky", so > that

[PATCH 3/4] dir.c: support marking some patterns already matched

2016-02-15 Thread Nguyễn Thái Ngọc Duy
Given path "a" and the pattern "a", it's matched. But if we throw path "a/b" to pattern "a", the code fails to realize that if "a" matches "a" then "a/b" should also be matched. When the pattern is matched the first time, we can mark it "sticky", so that all files and dirs inside the matched path