💾 Archived View for tris.fyi › pydoc › glob captured on 2023-04-26 at 13:29:35. Gemini links have been rewritten to link to archived content

View Raw

More Information

⬅️ Previous capture (2023-01-29)

-=-=-=-=-=-=-

Back to module index

Go to module by name

glob

Filename globbing utility.

Functions

escape

escape(pathname)

  Escape all special characters.
    

glob

glob(pathname, *, root_dir=None, dir_fd=None, recursive=False)

  Return a list of paths matching a pathname pattern.

      The pattern may contain simple shell-style wildcards a la
      fnmatch. However, unlike fnmatch, filenames starting with a
      dot are special cases that are not matched by '*' and '?'
      patterns.

      If recursive is true, the pattern '**' will match any files and
      zero or more directories and subdirectories.
    

glob0

glob0(dirname, pattern)

glob1

glob1(dirname, pattern)

has_magic

has_magic(s)

iglob

iglob(pathname, *, root_dir=None, dir_fd=None, recursive=False)

  Return an iterator which yields the paths matching a pathname pattern.

      The pattern may contain simple shell-style wildcards a la
      fnmatch. However, unlike fnmatch, filenames starting with a
      dot are special cases that are not matched by '*' and '?'
      patterns.

      If recursive is true, the pattern '**' will match any files and
      zero or more directories and subdirectories.
    

Other members

magic_check = re.compile('([*?[])')
magic_check_bytes = re.compile(b'([*?[])')

Modules

contextlib

fnmatch

itertools

os

re

stat

sys