Pattern-matching utility functions for Sphinx.
Unknown Field: copyright | |
Copyright 2007-2022 by the Sphinx team, see AUTHORS. | |
Unknown Field: license | |
BSD, see LICENSE for details. |
Constant | DOTFILES |
Undocumented |
Class | Matcher |
A pattern matcher for Multiple shell-style glob patterns. |
Function | _translate_pattern |
Translate a shell-style glob pattern to a regular expression. |
Function | compile_matchers |
Undocumented |
Function | patfilter |
Return the subset of the list names that match the regular expression (pattern) pat. |
Function | patmatch |
Return if name matches the regular expression (pattern) pat`. Adapted from fnmatch module. |
Variable | _pat_cache |
Undocumented |
Translate a shell-style glob pattern to a regular expression.
Adapted from the fnmatch module, but enhanced so that single stars don't match slashes.
Parameters | |
pat:str | Undocumented |
Returns | |
str | Undocumented |
Undocumented
Parameters | |
patterns:List[ | Undocumented |
Returns | |
List[ | Undocumented |
Return the subset of the list names that match the regular expression (pattern) pat.
Adapted from fnmatch module.
Parameters | |
names:Iterable[ | Undocumented |
pat:str | Undocumented |
Returns | |
List[ | Undocumented |