Popularity
5.7
Growing
Activity
4.1
-
8
3
3
Monthly Downloads: 19
Programming language: Haskell
License: BSD 3-clause "New" or "Revised" License
Tags:
Development
FilePath
Latest version: v0.1.2
filepattern alternatives and similar packages
Based on the "Development" category.
Alternatively, view filepattern alternatives based on common mentions on social networks and blogs.
-
fourmolu
A fourk of ormolu that uses four space indentation and allows arbitrary configuration. Don't like it? PRs welcome! -
cabal-install-parsers
Scripts and instructions for using CI services (e.g. Travis CI or Appveyor) with multiple GHC configurations
SaaSHub - Software Alternatives and Reviews
SaaSHub helps you find the best software and product alternatives
Promo
www.saashub.com
Do you think we are missing an alternative of filepattern or a related project?
README
FilePattern

A library for matching files using patterns such as src/**/*.png for all .png files recursively under the src directory. There are two special forms:
*matches part of a path component, excluding any separators.**as a path component matches an arbitrary number of path components.
Some examples:
test.cmatchestest.cand nothing else.*.cmatches all.cfiles in the current directory, sofile.cmatches, butfile.handdir/file.cdon't.**/*.cmatches all.cfiles anywhere on the filesystem, sofile.c,dir/file.c,dir1/dir2/file.cand/path/to/file.call match, butfile.handdir/file.hdon't.dir/*/*matches all files one level belowdir, sodir/one/file.canddir/two/file.hmatch, butfile.c,one/dir/file.c,dir/file.handdir/one/two/file.cdon't.
More complete semantics are given in the documentation for the matching function ?==.
Features
- All matching is O(n). Most functions precompute some information given only one argument. There are also functions to provide bulk matching of many patterns against many paths simultaneously, see
stepandmatchMany. - You can obtain the parts that matched the
*and**special forms usingmatch, and substitute them into other patterns usingsubstitute. - You can search for files using a minimal number of IO operations, using the System.FilePattern.Directory module.
Related work
- Another Haskell file pattern matching library is Glob, which aims to be closer to the POSIX
glob()function, with forms such as*,?,**/(somewhat different to thefilepatternequivalent) and[:alpha:]. A complete guide is in the documentation. Compared tofilepattern, theGloblibrary is closer to a regular expression library - definitely more powerful, potentially harder to use. - The
shakelibrary has contained aFilePatterntype since the beginning. This library evolved from that code, with significant improvements. - The semantics are heavily inspired by VS Code, Git and the NPM package Glob.