Skip to content

Commit

Permalink
Ignore more macOS specific files and directories
Browse files Browse the repository at this point in the history
  • Loading branch information
cbenhagen committed Sep 1, 2020
1 parent eedbc65 commit e0164c0
Showing 1 changed file with 15 additions and 2 deletions.
17 changes: 15 additions & 2 deletions ocopy/copy.py
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,20 @@ def copytree(
for d in destinations:
d.mkdir(parents=True, exist_ok=True)

ignored_files = [".DS_Store", ".fseventsd"]
ignored_paths = [
".DS_Store",
".DocumentRevisions-V100",
".Spotlight-V100",
".Spotlight",
".TemporaryItems",
".Trashes",
".VolumeIcon.icns",
"._.TemporaryItems",
"._.Trashes",
".com.apple.timemachine.donotpresent",
".fseventsd",
"System Volume Information",
]

file_infos = []
errors = []
Expand All @@ -111,7 +124,7 @@ def copytree(
if _is_cancelled():
break

if src_path.name in ignored_files:
if src_path.name in ignored_paths:
continue
dst_paths = [d / src_path.name for d in destinations]
try:
Expand Down

0 comments on commit e0164c0

Please sign in to comment.