# -*- coding: UTF-8 -*-
import os
from time import sleep
# 文件夹遍历处理函数
def directorTraver(path):
sleep(1);
# 循环这个目录
for item in os.scandir(path=path):
# 如果item是文件夹
if item.is_dir():
#就遍历这个文件夹
directorTraver(item.path);
#如果这个是文件
elif item.is_file():
# 输出这个文件
print(item.path);
if __name__ == '__main__':
path = '/home/windstorm/Documents/'
directorTraver(path=path);