Firstly I want to thank Phil for this really great product. I use it all the time for my personal and business needs.
But there is one issue that I can't resolve.
When I set some tags/comment in Finder I can read them with
exiftool -MDItemUserTags -MDItemFinderComment checkMetadata.jpg
But when I upload that file to GoogleDrive and download it again, these tags are missing.
Is there any way to preserve Finder's tags and comments in file's metadata when uploading to the cloud? I have folder with files and lots of nested folders with different images and videos. Maybe I can execute ExifTool to somehow go through all of them and write all Finder tags/comments to lets say XMP:keywords/XMP:comment ?
Thanks in advance!
Quote from: PavloAndriiesh on October 08, 2018, 03:34:49 PMBut when I upload that file to GoogleDrive and download it again, these tags are missing.
Those tags are properties of the file system. You will lose them any time the file is moved to a non-mac filesystem.
QuoteMaybe I can execute ExifTool to somehow go through all of them and write all Finder tags/comments to lets say XMP:keywords/XMP:comment ?
That would be something you can do, though you'll have to figure out which tags you want to write to, as XMP:keywords/XMP:comment aren't tags unless you make them your self.
XMP:Subject would be the appropriate place to copy keywords to, while
XMP:Description would probably be the best place to put the comment, unless you're using it for something else.
I don't use a Mac so I could be a bit off with this, but I would suggest trying out this for your command:
exiftool '-Subject<MDItemUserTags' '-Description<MDItemFinderComment' FileOrDirYou can add the
-r option (https://exiftool.org/exiftool_pod.html#r-.--recurse) to recurse into subdirectories.
Quote from: StarGeek on October 08, 2018, 04:54:02 PM
Those tags are properties of the file system. You will lose them any time the file is moved to a non-mac filesystem.
I don't use a Mac so I could be a bit off with this, but I would suggest trying out this for your command:
exiftool '-Subject<MDItemUserTags' '-Description<MDItemFinderComment' FileOrDir
You can add the -r option (https://exiftool.org/exiftool_pod.html#r-.--recurse) to recurse into subdirectories.
That's what I was looking for. Now I know that for sure. Thank you!
Are finder tags extended attributes? If so, the answer might be to make a tar archive before storing externally.
https://forums.macrumors.com/threads/tar-and-extended-attributes.1838892/ (https://forums.macrumors.com/threads/tar-and-extended-attributes.1838892/)
I was wondering what archive formats (zip, 7z, rar, etc) might be able to keep them intact.
The best way that worked for me was this:
exiftool '-Description<MDItemFinderComment' '-Subject<MDItemUserTags' -overwrite_original_in_place -r PATH_TO_FOLDER
The only possible problem that Description and Subject would be rewritten by this tags. But that's better then loose Finder tags and comment
Hi everyone.
Once again I issued some strange behaviour. I believe that this is a bug in exiftool. So what I discovered is exiftool can't see MDItemUserTags value for some cases.
How i tested:
1. I have a file with "Green" user tag in Finder. I can see that "Green" tag in Finder and in "Get info" window.
2. I use command exiftool -MDItemUserTags 1.jpg
and i get nothing
3. I add any tag in Finder and repeat command - a result is MD Item User Tags : Green, Gray
4. I remove Gray from tags and repeat command:MD Item User Tags : Green
So that's made me think that there is some bug. I am trying to find a workaround to make it easy to add and then remove some fake tag to all files in folders recursively so I don't do it manually.
Unfortunately I cannot edit MDItemUserTags, trying command exiftool -MDItemUserTags="test" /Users/pavloandriiesh/Downloads/123123.jpg
throws error Warning: Error 32512 running "tag" to set MDItemUserTags - /Users/pavloandriiesh/Downloads/123123.jpg
Some help would be highly appreciated :)
For someone experiencing same bug - there is a workaround.
If adding/removing Finder tags make the initial tag visible - we should add/remove some fake tag on all files.
Best way I found - install Hombrew's tag: brew install tag
Then its easy to use it:
Add tag to all files and subfolders recursively: tag -a fakeTag -R /pathToFolder/*
Remove tag from all files and subfolders recursively: tag -r fakeTag -R /pathToFolder/*
Quote from: PavloAndriiesh on October 30, 2018, 05:45:29 AM
Once again I issued some strange behaviour. I believe that this is a bug in exiftool. So what I discovered is exiftool can't see MDItemUserTags value for some cases.
This is not an ExifTool bug. MacOS takes some time to update the MDItemTags, so you sometimes have to wait a while before reading them to see what you have just written.
- Phil
Quote from: Phil Harvey on October 31, 2018, 06:39:17 AM
This is not an ExifTool bug. MacOS takes some time to update the MDItemTags, so you sometimes have to wait a while before reading them to see what you have just written.
- Phil
Oh, now it's clear. Thanks for clarification Phil. And thanks for this awesome tool :)
I will add this to the MacOS tags documentation:
Note that these tags do not necessarily reflect the current metadata
of a file -- it may take some time for the MacOS mdworker daemon to
index the file after the metadata changes.
- Phil