Skip to content
Search

Python:fnmatch

lastmod 2021-09-12created 2021-09-122 edits

Unix filename pattern matching.

This module provides support for Unix shell-style wildcards, which are not the same as regular expressions (which are documented in the re module).

Rules

The special characters used in shell-style wildcards are:

Pattern

Meaning

*

matches everything

?

matches any single character

[seq]

matches any character in seq.

[!seq]

matches any character not in seq

See also

Favorite site

author Zer0 sitemap