reversing first name and last name

Started by bungaman, May 24, 2023, 10:51:50 AM

Previous topic - Next topic

bungaman

how would one reverse first name and last name in xmp face tags?  any suggestions.

Phil Harvey

Maybe something like this:

exiftool -api filter="s/(\S+) (\S+)/$2 $1/" -tagsfromfile @ -TAG1 -TAG2 FILE

where TAG1 and TAG2 (etc) are the tags you want changed.  This will swap the first 2 words of the tag value.

- 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 ($).

bungaman

worked great - thanks for the quick response!!!
 ;D