Backend: Ignore comments in .ppignore files #233 #287

Signed-off-by: Michael Mayer <michael@liquidbytes.net>
This commit is contained in:
Michael Mayer 2020-05-04 10:10:56 +02:00
parent 18c0f15191
commit 4e9e84ac9a
2 changed files with 3 additions and 1 deletions

View file

@ -84,7 +84,7 @@ func (l *IgnoreList) AppendItems(dir string, patterns []string) error {
}
for _, pattern := range patterns {
if pattern != "" {
if pattern != "" && !strings.HasPrefix(pattern, "#") {
l.items = append(l.items, NewIgnoreItem(dir, pattern, l.caseSensitive))
}
}

View file

@ -1,4 +1,6 @@
*.txt
test.md
# This is a comment
somefile.*
baz*