abe33 / atom-pigments

An Atom package to display colors in project and files.
MIT License
524 stars 68 forks source link

Fix default ignored globs for variable scanning #476

Closed nlydv closed 2 years ago

nlydv commented 2 years ago

I noticed that the autocomplete for color variables was showing me colors that I didn't create and I happened to know belong to a certain vendor project, which should not have been picked up by Pigments since the ignored file glob setting for this included vendor/* by default.

After a bit of playing with that setting, realized that it needs "absolute" globs to work properly (relative to project root, I guess?). So vendor/* changed to **/vendor did the trick for me without ignoring my actual color variables.

For this PR, I made that change to the default glob parameters in the package.json. To potentially reduce resource usage for others, I also added a few extra globs matching locations commonly found in a website folder structure that clearly wouldn't be of interest to search (e.g. **/font, **/img, and the like).

Cxarli commented 2 years ago

Thanks!