summaryrefslogtreecommitdiffstats
path: root/Doc/library/os.rst
diff options
context:
space:
mode:
Diffstat (limited to 'Doc/library/os.rst')
-rw-r--r--Doc/library/os.rst11
1 files changed, 9 insertions, 2 deletions
diff --git a/Doc/library/os.rst b/Doc/library/os.rst
index 7d2ec60..69dd5c4 100644
--- a/Doc/library/os.rst
+++ b/Doc/library/os.rst
@@ -1741,8 +1741,11 @@ features:
Recursive directory creation function. Like :func:`mkdir`, but makes all
intermediate-level directories needed to contain the leaf directory.
- The *mode* parameter is passed to :func:`mkdir`; see :ref:`the mkdir()
- description <mkdir_modebits>` for how it is interpreted.
+ The *mode* parameter is passed to :func:`mkdir` for creating the leaf
+ directory; see :ref:`the mkdir() description <mkdir_modebits>` for how it
+ is interpreted. To set the file permission bits of any newly-created parent
+ directories you can set the umask before invoking :func:`makedirs`. The
+ file permission bits of existing parent directories are not changed.
If *exist_ok* is ``False`` (the default), an :exc:`OSError` is raised if the
target directory already exists.
@@ -1767,6 +1770,10 @@ features:
.. versionchanged:: 3.6
Accepts a :term:`path-like object`.
+ .. versionchanged:: 3.7
+ The *mode* argument no longer affects the file permission bits of
+ newly-created intermediate-level directories.
+
.. function:: mkfifo(path, mode=0o666, *, dir_fd=None)