elm-review/docs.json

1 line
235 KiB
JSON
Raw Normal View History

2024-06-14 18:51:30 +03:00
[{"name":"Review.FilePattern","comment":" A module for selecting multiple files from the file system\nusing [`glob`] patterns and negated patterns.\n\n import Review.FilePattern as FilePattern\n\n filePatterns =\n [ FilePattern.include \"**/*.css\"\n , FilePattern.exclude \"**/*-test.css\"\n , FilePattern.excludeDirectory \"ignore-folder/\"\n ]\n\nSome `elm-review` APIs require a `List FilePattern` as an argument to figure out a list of files to match or not match.\n\nThis list works similar like [`.gitignore`] files: any matching file excluded by a previous pattern will become included again.\nFiles that are in [excluded directories](#excludeDirectory) are ignored entirely.\n\nA file pattern is always relative to the project's `elm.json` file, is case-sensitive,\nand should be written in the Unix style (`src/Some/File.elm`, not `src\\Some\\File.elm`).\n\n@docs FilePattern\n@docs include, exclude, excludeDirectory\n\n\n## Supported patterns\n\nThe supported patterns are the following:\n\n - `?` matches an unknown single character (except `/`). \"a?c\" would match \"abc\" or \"a5c\", but not \"ac\".\n - `*` matches any number of unknown characters (except `/`). \"some-\\*.txt\" would match \"some-file.txt\" and \"some-other-file.txt\", but not \"other-file.txt\" or \"some-folder/file.txt\".\n - `**` matches any number of sub-directories. \"projects/**/README.md\" would match \"projects/README.md\", \"projects/a/README.md\" and \"projects/a/b/README.md\". If you desire to include all files in a folder, then you need to end the pattern with `/**/*` (eg \"projects/**/\\*\" or \"projects/\\*\\*/\\*.md\").\n - `[characters]` matches one of the specified characters. `a[bc]d` would match \"abc\" and \"acd\", but not \"axd\".\n - `[^characters]` matches anything that is not one of the specified characters. `a[^bc]d` would match \"axc\", but not \"abd\" or \"acd\".\n - `[character1-character2]` matches a range of characters. `a[a-z]d` would match \"aac\" and \"azd\", but not \"a5d\".\n - `{string1|string2}` matches one of the provided strings. \"file.{js|ts}\" would match \"file.js\" and \"file.ts\" but not \"file.md\".\n\n\n## Using FilePattern\n\n@docs Summary, compact, match\n@docs toStrings\n\n[`glob`]: https://en.wikipedia.org/wiki/Glob_%28programming%29\n[`.gitignore`]: https://git-scm.com/docs/gitignore#_pattern_format\n\n","unions":[{"name":"FilePattern","comment":" A pattern to included or exclude files from a selection.\n","args":[],"cases":[]},{"name":"Summary","comment":" Compiled version of a list of `FilePattern`s.\nThis is done to have good performance.\n","args":[],"cases":[]}],"aliases":[],"values":[{"name":"compact","comment":" Compile a list of `FilePattern`s.\nThis is done to have good performance.\n","type":"List.List Review.FilePattern.FilePattern -> Result.Result (List.List String.String) Review.FilePattern.Summary"},{"name":"exclude","comment":" Create a `FilePattern` that excludes files that match a Glob-like pattern.\n\n [ FilePattern.include \"**/*.css\"\n , FilePattern.exclude \"exception.css\"\n ]\n\nFiles that get excluded this way can be re-included through `FilePattern.include`.\n\n [ FilePattern.include \"**/*.css\"\n , FilePattern.exclude \"exception-*.css\"\n , FilePattern.include \"exception-among-exceptions.css\"\n ]\n\n","type":"String.String -> Review.FilePattern.FilePattern"},{"name":"excludeDirectory","comment":" Create a `FilePattern` that excludes a whole directory.\nFiles that get excluded this way can't be re-included.\n\n [ FilePattern.include \"**/*.css\"\n , FilePattern.excludeDirectory \"build/\"\n ]\n\n","type":"String.String -> Review.FilePattern.FilePattern"},{"name":"include","comment":" Create a `FilePattern` that includes files that match a Glob-like pattern.\n\n [ FilePattern.include \"CHANGELOG.md\"\n , FilePattern.include \"src/**/*.elm\"\n , FilePattern.include \"*.css\"\n ]\n\n","type":"String.String -> Review.FilePattern.FilePattern"},{"name":"match","comment":" Check if a file path match