How can I export file comments in Finder to an editable file?

I have a few folders with 100+ files where I wrote important information into the "Get Info" Comments field. Need to export that to an editable file, but there's way too many files to do so manually. I found a post on here but the solution doesn't work for me, potentially because it's offered for Mavericks and I'm running Big Sur.


Any way to automate this?

MacBook Air 13″, macOS 11.6

Posted on Dec 3, 2022 02:04 AM

Reply
Question marked as Top-ranking reply

Posted on Dec 3, 2022 05:24 AM

I would revise this to eliminate everything but the comment text in the output and there are other tweaks that are also possible:


exiftool -q -s3 -if '$MDItemFinderComment' -p '$filename: $MDItemFinderComment' . 2> /dev/null > ~/Desktop/comments.txt


output:

image_rename.csv: I am a CSV file.
foo.jpg: I am an empty image file.


It will not process any file without a Finder comment, suppresses the directory and file totals, and the s3 only writes out the comment itself. Finally the shell redirect 2> ignores exiftool error messages when it encounters an empty file:


Error: File is empty - ./foo.jpg


Similar questions

5 replies
Question marked as Top-ranking reply

Dec 3, 2022 05:24 AM in response to Matti Haveri

I would revise this to eliminate everything but the comment text in the output and there are other tweaks that are also possible:


exiftool -q -s3 -if '$MDItemFinderComment' -p '$filename: $MDItemFinderComment' . 2> /dev/null > ~/Desktop/comments.txt


output:

image_rename.csv: I am a CSV file.
foo.jpg: I am an empty image file.


It will not process any file without a Finder comment, suppresses the directory and file totals, and the s3 only writes out the comment itself. Finally the shell redirect 2> ignores exiftool error messages when it encounters an empty file:


Error: File is empty - ./foo.jpg


This thread has been closed by the system or the community team. You may vote for any posts you find helpful, or search the Community for additional answers.

How can I export file comments in Finder to an editable file?

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple Account.