SuperchupuDev / tinyglobby

A fast and minimal alternative to globby and fast-glob
https://npmjs.com/package/tinyglobby
MIT License
150 stars 9 forks source link

Unexpected behavior: node_modules Ignored when combined with other patterns #58

Closed j0nl1 closed 1 month ago

j0nl1 commented 1 month ago

I'm not sure if this is the expected behavior, but it seems quite different from how fast-glob works. Essentially, when adding the node_modules folder and another pattern, the node_modules directory is ignored completely.

You can find a simple example reproducing this issue here: https://stackblitz.com/edit/tinyglobby-behavior?file=glob.ts&view=editor

Is this the intended behavior? Any clarification would be appreciated!

Thanks in advance.

SuperchupuDev commented 1 month ago

the node_modules folder generated by pnpm contains symlinks to packages from node_modules/.pnpm. sadly symlinks resolution had to be temporarily reverted due to a critical upstream bug, it will be reenabled once it gets fixed. you can track the following issues meanwhile:

in theory, it should work once symlinks resolution is added back. meanwhile, i'm closing this as a duplicate of #10

by the way, unrelated to symlinks: you should set the expandDirectories tinyglobby option to false if you want to match fast-glob's behavior as much as possible

SuperchupuDev commented 1 month ago

fixed in 0.2.10. can you confirm that the issue is solved?