Automator doesn't seem to play nicely with setting multiple values to the same tag, in priority order, as described in example 12 here: https://exiftool.org/filename.html.
For whatever reason, this doesn't work in Automator, but does work directly from the command line. Automator doesn't even output to the log file. Any ideas what's going on and how to fix?
/usr/local/bin/exiftool -d /FamilyMedia/Photos/%Y/%m/%Y%m%d_%H%M_%%f.%%e '-filename<DateCreated' '-filename<CreateDate' '-filemodifydate<DateCreated#' '-filemodifydate<CreateDate#' "$@" >> /FamilyMedia/Intake/Log.text
I have no experience with automator, but aside from possible quoting differences, the redirection is the only thing I would expect to be different. Redirection is handled by the shell, so your output to Log.text is dependent on how Automator handles the redirection.
Having multiple arguments in the same command should certainly be possible in automator, so I don't understand why you say it "doesn't work".
- Phil
Two things I can think of:
1) your Automator "Run Shell Script" action needs to specify the full path to your directories. (Automator won't "cd"). Something like
$HOME/FamilyMedia/Photos/.....
or if it's an external drive,
/Volumes/FamilyMedia/Photos/.....
may help.
2) You may need to tell the Automator action to pass inputs as arguments. The default setting is "to stdin". (Screen grab attached as an example.)
Hope this helps, happy Christmas! :)