exclude-indexing-filetree icon indicating copy to clipboard operation
exclude-indexing-filetree copied to clipboard

.gitignore lines starting with "/" don't work

Open brendanlong opened this issue 9 years ago • 2 comments

I have a .gitignore like:

/bin
/include
/lib

__pycache__
.Python

pip-selfcheck.json
pyvenv.cfg

The /bin, /include and /lib lines seem to be completely ignored. Removing the starting slash fixes it, but those lines are specific like that for a reason..

brendanlong avatar Nov 15 '16 17:11 brendanlong

Hey @DimitrK I have find a related issue too. I think something about file extensions in gitignore is broken. In my current project I'm excluding .settings files only in the root folder (/) but I notice that the plugin hides files named _settings (with another file extension) in a child folder. I attach you a screenshot to better explain. gitignore fails

rzecchini avatar Dec 15 '16 09:12 rzecchini

It looks like maybe .gitignore lines are being treated as regular expressions instead of something-similar-to-a-glob?

Maybe consider using this?

https://github.com/codemix/gitignore-parser

brendanlong avatar Jan 03 '17 15:01 brendanlong