mirror of
https://github.com/ciromattia/kcc
synced 2026-09-01 16:37:06 +00:00
Remove Windows silly 'thumbs.db' too
This commit is contained in:
+1
-1
@@ -557,7 +557,7 @@ def slugify(value):
|
|||||||
def sanitizeTree(filetree):
|
def sanitizeTree(filetree):
|
||||||
for root, dirs, files in os.walk(filetree):
|
for root, dirs, files in os.walk(filetree):
|
||||||
for name in files:
|
for name in files:
|
||||||
if name.startswith('.'):
|
if name.startswith('.') or name.lower() == 'thumbs.db':
|
||||||
os.remove(os.path.join(root, name))
|
os.remove(os.path.join(root, name))
|
||||||
else:
|
else:
|
||||||
splitname = os.path.splitext(name)
|
splitname = os.path.splitext(name)
|
||||||
|
|||||||
Reference in New Issue
Block a user