mirror of
https://github.com/python/cpython.git
synced 2025-10-12 09:53:19 +00:00
New doc strings.
This commit is contained in:
parent
fd79566d0f
commit
ab096c91e2
1 changed files with 6 additions and 1 deletions
|
@ -1,4 +1,4 @@
|
||||||
# Module 'glob' -- filename globbing.
|
"""Filename globbing utility."""
|
||||||
|
|
||||||
import os
|
import os
|
||||||
import fnmatch
|
import fnmatch
|
||||||
|
@ -6,6 +6,11 @@ import regex
|
||||||
|
|
||||||
|
|
||||||
def glob(pathname):
|
def glob(pathname):
|
||||||
|
"""Return a list of paths matching a pathname pattern.
|
||||||
|
|
||||||
|
The pattern may contain simple shell-style wildcards a la fnmatch.
|
||||||
|
|
||||||
|
"""
|
||||||
if not has_magic(pathname):
|
if not has_magic(pathname):
|
||||||
if os.path.exists(pathname):
|
if os.path.exists(pathname):
|
||||||
return [pathname]
|
return [pathname]
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue