def _is_hidden(entry, follow_symlinks=True):
# note: *entry* can be a DirEntry or a FsEntry
if entry.name[0] is ".":
return True
if _IS_WINDOWS:
attr = entry.stat(follow_symlinks=follow_symlinks).st_file_attributes
if attr & stat.FILE_ATTRIBUTE_HIDDEN:
return True
return False
评论列表
文章目录