ExifTool & Apple Automator

Started by Stephen Marsh, December 02, 2016, 12:18:25 AM

Previous topic - Next topic

Stephen Marsh

There are a number of topic threads on the site covering the use of ExifTool from within Apple Automator.

It is a rare event when I can give back to this community, so I hope that this helps somebody else in need.

Basic Automator Service Example: Remove All Metadata




Advanced Automator Service Example: Append Multiple Keywords Using a Variable & Comma Separator



Phil Harvey

Hi Stephen,

Thanks for the post.

Just one comment:  You have two -sep options in your keywords command.  It is only the last one that will be effective: -sep ', ' (ie. the one with the space)  So you can remove the first one from the command.

- Phil
...where DIR is the name of a directory/folder containing the images.  On Mac/Linux/PowerShell, use single quotes (') instead of double quotes (") around arguments containing a dollar sign ($).

Stephen Marsh

Thanks Phil, I was trying to cover both input cases – keyword1,keyword2, keyword3 etc. where the keywords may or may not have a space after the comma. I am sure that I tested this months ago when I first worked out how to tie together variables and sep input, which is why I ended up with both in there. Now you have me doubting my memory.

Hayo Baan

You didn't need the first one as spaces are taken care of specially already :). From the documentation:
Quote-sep STR (-separator)
Specify separator string for items in list-type tags. When reading, the default is to join list items with '', ''. When writing, this option causes values assigned to list-type tags to be split into individual items at each substring matching STR (otherwise they are not split by default). Space characters in STR match zero or more whitespace characters in the value.
Hayo Baan – Photography
Web: www.hayobaan.nl

Stephen Marsh

Thanks again Phil, Hayo.

I wanted to correct the link and attachments in my OP, however the edit button is not available.