diff options
author | Giampaolo Rodola' <g.rodola@gmail.com> | 2012-05-15 13:30:25 (GMT) |
---|---|---|
committer | Giampaolo Rodola' <g.rodola@gmail.com> | 2012-05-15 13:30:25 (GMT) |
commit | ffa1d0b8d53f426f1f9a0d47f25440b8994c4fb0 (patch) | |
tree | 2c5626573e004979e0c38b58ed9ce31a3c96dcb5 /Doc/library/stat.rst | |
parent | 41829e82c1826dd71b64f8334959bcf7731f66fc (diff) | |
download | cpython-ffa1d0b8d53f426f1f9a0d47f25440b8994c4fb0.zip cpython-ffa1d0b8d53f426f1f9a0d47f25440b8994c4fb0.tar.gz cpython-ffa1d0b8d53f426f1f9a0d47f25440b8994c4fb0.tar.bz2 |
#14807: move undocumented tarfile.filemode() to stat.filemode(). Add tarfile.filemode alias with deprecation warning.
Diffstat (limited to 'Doc/library/stat.rst')
-rw-r--r-- | Doc/library/stat.rst | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/Doc/library/stat.rst b/Doc/library/stat.rst index 7de98b6..f47f464 100644 --- a/Doc/library/stat.rst +++ b/Doc/library/stat.rst @@ -104,6 +104,16 @@ Example:: if __name__ == '__main__': walktree(sys.argv[1], visitfile) +An additional utility function is provided to covert a file's mode in a human +readable string: + +.. function:: filemode(mode) + + Convert a file's mode to a string of the form '-rwxrwxrwx'. + + .. versionadded:: 3.3 + + All the variables below are simply symbolic indexes into the 10-tuple returned by :func:`os.stat`, :func:`os.fstat` or :func:`os.lstat`. @@ -344,4 +354,3 @@ The following flags can be used in the *flags* argument of :func:`os.chflags`: The file is a snapshot file. See the \*BSD or Mac OS systems man page :manpage:`chflags(2)` for more information. - |