Replace fast-glob with tinyglobby
Closes #1446
Thanks for bringing this up again, and the efforts already put in. I'm going to change the title to make it clear that we should really only merge if we can get this right.
looks like there are 4 places where the firstGlob function is used
https://github.com/webpro-nl/knip/blob/5b98269b0ce28890a8a16559846188dd2016bf25/packages/knip/src/plugins/yarn/index.ts#L10
https://github.com/webpro-nl/knip/blob/5b98269b0ce28890a8a16559846188dd2016bf25/packages/knip/src/plugins/taskfile/index.ts#L21
https://github.com/webpro-nl/knip/blob/5b98269b0ce28890a8a16559846188dd2016bf25/packages/knip/src/plugins/github-actions/index.ts#L15
https://github.com/webpro-nl/knip/blob/5b98269b0ce28890a8a16559846188dd2016bf25/packages/knip/src/plugins/pnpm/index.ts#L11
@webpro I removed 2 of the usages and will see if I can deal with the other 2
removed another one
removed the last one
Could use fsPromises.glob as well, given that it's available in Node 22 and greater which matches the minimum version of this module.
Knip requires at least Node.js v18, tinyglobby v12. And I don't expect Knip to reach the fs.glob threshold too soon, as it might be helpful in legacy projects trying to keep up. That said, using built-ins is usually a good idea once we can (but tbh haven't looked into differences here recently).
Ah sorry, I was looking at the wrong package.json, carry on :D
#1462