:rocket: It's a very fast and efficient glob library for Node.js
Full Changelog: https://github.com/mrmlnc/fast-glob/compare/3.3.1...3.3.2
Full Changelog: https://github.com/mrmlnc/fast-glob/compare/3.3.0...3.3.1
This release fixes a regression for cases where the ignore
option is used with a string (#403, #404).
The public interface of this package does not support a string as the value for the ignore
option since 2018 year (release).
So, in the next major release, we will reintroduce method implementations that do not involve strings in the ignore
option.
Full Changelog: https://github.com/mrmlnc/fast-glob/compare/3.2.12...3.3.0
Method aliases
New methods (glob
, globSync
, globStream
) have been added in addition to the current methods (default import, sync
, stream
), which eliminate the need to rename the method when importing. In addition, an async
alias has been added for the default import, which makes it possible to use this packet with ESM.
Method to convert paths to globs
A new method (convertPathToPattern
) has been added in this release to convert a path to a pattern. The primary goal is to enable users to avoid processing Windows paths in each location where this package is used by utilities from third-party packages.
See more details in the pull request.
baseNameMatch
option was enabled, which went against the documented behavior. (#312)micromatch
package does not correctly generate a regular expression (#365).dot
option enabled when matching paths. Previously, the !**/*
patterns did not exclude hidden files (start with a dot). (#343)['./file.md', 'file.md', '*']
will now only include file.md
once in the results. (#190)A clarifying note has been added for the concurrency
option, which provides more detailed information about the Thread Pool utilization.
Full Changelog: https://github.com/mrmlnc/fast-glob/compare/3.2.11...3.2.12
Fixed an issue introduced in 3.2.7
related to incorrect application of patterns to entries with a trailing slash when the entry is not a directory.
Before changes:
fg.sync('**/!(*.md)')
// ['file.md', 'a/file.md', 'a/file.txt']
After fix:
fg.sync('**/!(*.md)')
// ['a/file.txt']
Thanks @AgentEnder for the issue (#357).
This release includes performance improvements for the asynchronous method. For this method we now use an asynchronous directory traversal interface instead of using a streaming interface. This gives up to 15% acceleration for medium and large directories. The result depends a lot on hardware.
You can find the benchmark results for this release in CI here.
Here are a few of measurements on my laptop:
===> Benchmark pattern "*" with 100 launches (regression, async)
===> Max stdev: 7 | Retries: 3 | Options: {}
Name Time, ms Time stdev, % Memory, MB Memory stdev, % Entries Errors Retries
--------------------- -------- ------------- ---------- --------------- ------- ------ -------
fast-glob-current.js 4.390 0.252 6.253 0.015 4 0 1
fast-glob-previous.js 5.653 0.633 6.051 0.056 4 0 1
===> Benchmark pattern "**" with 100 launches (regression, async)
===> Max stdev: 7 | Retries: 3 | Options: {}
Name Time, ms Time stdev, % Memory, MB Memory stdev, % Entries Errors Retries
--------------------- -------- ------------- ---------- --------------- ------- ------ -------
fast-glob-current.js 34.587 1.287 10.654 0.607 11835 0 1
fast-glob-previous.js 41.972 2.086 10.236 1.224 11835 0 1
Full Changelog: https://github.com/mrmlnc/fast-glob/compare/3.2.10...3.2.11
Yeap, this is another release aimed at fixing problems with detecting brace expansions in patterns. This time, patterns like abc/{a.txt,b.js}
was not marked as a dynamic pattern. So, now the regex has been rewritten to a generalized solution as a function to avoid future problems due to the complexity of the regular expression.
Thanks @MurzNN for the report of this problem (#351).
Full Changelog: https://github.com/mrmlnc/fast-glob/compare/3.2.9...3.2.10
3.2.8
when the {a,b,c}
pattern no longer considered a dynamic pattern (thanks @amitdahan, #347).Full Changelog: https://github.com/mrmlnc/fast-glob/compare/3.2.8...3.2.9
3.2.8
with invalid regular expression on older node.js versions (#345).Full Changelog: https://github.com/mrmlnc/fast-glob/compare/3.2.7...3.2.8
Thanks @Trott for investigating the problem and the detailed description.
Previously the src/*/
pattern did not work as expected (like src/*
).
Starting from this release, patterns like src//*
will work like similar patterns without duplicate slashes. This was done for continuity with other solutions (glob
, ls src//*
, python, golang, …).
Thanks @Trott for fixing bugs and @XhmikosR for adding the CodeQL action to CI pipeline.
The previous release (3.2.6
) introduced a regression, which makes negative patterns were not applied to patterns outside the current directory.
This release fixes the issue.
// Patterns inside current directory → ['*', './*.js']
// Patterns outside current directory → ['../*', './../*.js']
// Previously you could specify a patterns outside current directory.
fg.sync(['../*.txt']) → ['../file.txt']
// But when the pattern inside current directory was added to them, the behavior broke down.
fg.sync(['*.md', '../*.txt']) → ['file.md'] // The '../file.txt' file exists
// After this fix you can mix both kinds of patterns.
fg.sync(['*.md', '../*.txt']) → ['file.md', '../file.txt']
// Right now we do not support patterns like '{.,..}/*.md'.
followSymbolicLinks
option.glob-parent
package has been updated to fix vulnerabilities. (#304)micromatch
package has been updated to eliminate dependency on the picomatch
package from this package. (#256)tiny-glob
package has been added to the synchronous product benchmarks. (#323)fdir
package has been added to synchronous and asynchronous product benchmarks. The latest launch. (#322).npmignore
file has been replaced by the files
field in the package.json
file. (#321)