Hi, I'm using exiftool for over a year to handle my archive of images. Today I stubbled over a strange behaviour when using escape characters. I installed a fresh version 12.36 but it still happens.
1. Take an xmp file without subjects, e.g.
exiftool -ex -p '$subject' D079_08.xmp
Warning: [Minor] Tag 'subject' not defined - D079_08.xmp
2. Add a subject with apostrophes:
exiftool "-subject+=Rock'n'Roll" D079_08.xmp
exiftool -ex -p '$subject' D079_08.xmp
Rock'n'Roll
This is as expected and identical to the content of the xmp file.
3. Add another subject :
exiftool "-subject+=Karneval" D079_08.xmp
exiftool -ex -p '$subject' D079_08.xmp
Rock'n'Roll, Karneval
Suddenly there are & in the output. What is going wrong?
Best regards,
Armin
Hi Armin,
The -ex option formats the output in XML.
The -p option is user-specified formatting.
These options are not compatible.
- Phil
Hi Phil,
thanks for the insight. I've rewritten my script in perl using the exiftool interface ;)
And of course thanks for the superb tool!
Armin