|
|
@ -1,4 +1,5 @@
|
|
|
|
import os
|
|
|
|
import os
|
|
|
|
|
|
|
|
import sys
|
|
|
|
|
|
|
|
|
|
|
|
from .common import PostProcessor
|
|
|
|
from .common import PostProcessor
|
|
|
|
from ..utils import (
|
|
|
|
from ..utils import (
|
|
|
@ -54,8 +55,8 @@ class XAttrMetadataPP(PostProcessor):
|
|
|
|
if infoname == 'upload_date':
|
|
|
|
if infoname == 'upload_date':
|
|
|
|
value = hyphenate_date(value)
|
|
|
|
value = hyphenate_date(value)
|
|
|
|
elif xattrname == 'com.apple.metadata:kMDItemWhereFroms':
|
|
|
|
elif xattrname == 'com.apple.metadata:kMDItemWhereFroms':
|
|
|
|
# NTFS ADS doesn't support colons in names
|
|
|
|
# Colon in xattr name throws errors on Windows/NTFS and Linux
|
|
|
|
if os.name == 'nt':
|
|
|
|
if sys.platform != 'darwin':
|
|
|
|
continue
|
|
|
|
continue
|
|
|
|
value = self.APPLE_PLIST_TEMPLATE % value
|
|
|
|
value = self.APPLE_PLIST_TEMPLATE % value
|
|
|
|
write_xattr(info['filepath'], xattrname, value.encode())
|
|
|
|
write_xattr(info['filepath'], xattrname, value.encode())
|
|
|
|