]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
docs: use 'recursively' in the description of rglob, and mention globs in the os...
authorNed Batchelder <ned@nedbatchelder.com>
Wed, 20 Jul 2022 21:47:43 +0000 (14:47 -0700)
committerGitHub <noreply@github.com>
Wed, 20 Jul 2022 21:47:43 +0000 (14:47 -0700)
The r in `rglob` stands for "recursively", so use the word in the description. Also, glob and rglob can usefully be mentioned as the pathlib equivalent of os.walk.

Automerge-Triggered-By: GH:brettcannon
Doc/library/pathlib.rst

index d5cda3adc8d512149db79e4429f7992a9c793668..04549184be2aea4bedac72c70247504937516aa3 100644 (file)
@@ -1122,8 +1122,8 @@ call fails (for example because the path doesn't exist).
 
 .. method:: Path.rglob(pattern)
 
-   This is like calling :func:`Path.glob` with "``**/``" added in front of the
-   given relative *pattern*::
+   Glob the given relative *pattern* recursively.  This is like calling
+   :func:`Path.glob` with "``**/``" added in front of the *pattern*::
 
       >>> sorted(Path().rglob("*.py"))
       [PosixPath('build/lib/pathlib.py'),