diff options
Diffstat (limited to 'Lib/ntpath.py')
-rw-r--r-- | Lib/ntpath.py | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/Lib/ntpath.py b/Lib/ntpath.py index 4e7bb885a9..d6b69208df 100644 --- a/Lib/ntpath.py +++ b/Lib/ntpath.py @@ -11,7 +11,7 @@ import sys __all__ = ["normcase","isabs","join","splitdrive","split","splitext", "basename","dirname","commonprefix","getsize","getmtime", - "getatime","islink","exists","isdir","isfile","ismount", + "getatime","getctime", "islink","exists","isdir","isfile","ismount", "walk","expanduser","expandvars","normpath","abspath","splitunc", "supports_unicode_filenames"] @@ -220,6 +220,9 @@ def getatime(filename): """Return the last access time of a file, reported by os.stat()""" return os.stat(filename).st_atime +def getctime(filename): + """Return the creation time of a file, reported by os.stat().""" + return os.stat(filename).st_ctime # Is a path a symbolic link? # This will always return false on systems where posix.lstat doesn't exist. |