Safe Haskell | None |
---|---|
Language | Haskell2010 |
Module that exposes all of the various GatherStrategy
types and functions
for dealing with them.
- data SingleFileGatherer
- data DirectoryGatherer
- data FileTreeGatherer
- data Gatherer
- data CommandGatherer
- wrapGatherStrategy :: GatherStrategy s => s -> Gatherer
- runGatherers :: [Gatherer] -> IO [Text]
- makeSingleFileGatherer :: Text -> Gatherer
- makeDirectoryGatherer :: Text -> FilterFunc -> Gatherer
- makeFileTreeGatherer :: Text -> FilterFunc -> Gatherer
- makeCommandGatherer :: IO () -> Gatherer
- matchAll :: FilterFunc
- matchExtension :: Text -> FilterFunc
- matchExtensionExcluded :: Text -> [Text -> Bool] -> FilterFunc
- matchExtensions :: [Text] -> FilterFunc
- matchExtensionsExcluded :: [Text] -> [Text -> Bool] -> FilterFunc
Documentation
data SingleFileGatherer Source #
Gatherer
that will return exactly one file.
data DirectoryGatherer Source #
Gatherer
that will return all files in a given directory (but not its
subdirectories) that pass the filter.
data FileTreeGatherer Source #
Gatherer
that will return all files in a given directory tree that pass
the filter.
Existential data type for wrapping GatherStrategy
s so they can be used
as a uniform type.
data CommandGatherer Source #
wrapGatherStrategy :: GatherStrategy s => s -> Gatherer Source #
Convenience function to turn a GatherStrategy
into a Gatherer
.
runGatherers :: [Gatherer] -> IO [Text] Source #
Runs a list of Gatherer
s and returns the concatenation of their output.
makeSingleFileGatherer :: Text -> Gatherer Source #
Constructs a Gatherer
that returns a single file.
makeDirectoryGatherer :: Text -> FilterFunc -> Gatherer Source #
Constructs a Gatherer
that returns all files in a directory (but not its
subdirectories) that match a given filter.
makeFileTreeGatherer :: Text -> FilterFunc -> Gatherer Source #
Constructs a Gatherer
that returns all files in a directory tree that
match a given filter.
makeCommandGatherer :: IO () -> Gatherer Source #
matchExtension :: Text -> FilterFunc Source #
Filter function that returns files with a given extension.
matchExtensionExcluded :: Text -> [Text -> Bool] -> FilterFunc Source #
Filter function that returns files with a given extension that don't match exclusion rules.
matchExtensions :: [Text] -> FilterFunc Source #
Filter function that returns files that match any of a list of extensions.