Commit ae42b27a authored by wanli's avatar wanli

update

parent b251980e
......@@ -18,7 +18,7 @@ config.read(os.path.join(os.getcwd(), "config.ini"))
def getSortDir(path):
lists = os.listdir(path)
print(lists)
lists.sort(key=lambda fn: os.path.getmtime(path + '\\' + fn))
lists.sort(key=lambda fn: os.path.getmtime(os.sep.join([path, fn])))
filepath = os.path.join(path, lists[-1])
print(filepath)
return filepath
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment