# kpmatch - Path patterns ## Pattern Syntax Path patterns should always use forward slashes `/` between segments. The actual separator used when matching paths depends on the system. A path segment containing two asterisks `/**/` matches zero, one or more segments. A single asterisk `*` matches zero, one or more characters except a path separator. A question mark `?` matches exactly one character unless it's a path separator. Square brackets `[ ]` can match one of the characters between the brackets. If the first character is an exclamation point `[! ]`, it will match one character that does NOT appear between the brackets. Curly braces `{ , }` can match one of the sub-expressions separated by commas. ## API ### Function `kpmatch.kpmatch(path: str | PathLike[str], pattern: str) -> bool` ### Method `kpmatch.Pattern.match(path: str | PathLike[str]) -> bool` Tests if a path matches a pattern.