import os,time
file_list=os.listdir("/home/xxxxxx/Desktop")
#print(file_list)
for file in file_list:
if '~' in file:
file_list.remove(file)
print(file_list)
for file in file_list:
(mode, ino, dev, nlink, uid, gid, size, atime, mtime, ctime) = os.stat(file)
print (file,"\nlast modified: %s" % time.ctime(mtime),'\nCreate time ',time.ctime(ctime),'\n')
沒有留言:
張貼留言