Image-ExifTool - Re: Replacing a keyword with another one in the keyword list

Posted on Wed Jul 2 17:27:19 2008 by exiftool in response to 8218 (See the whole thread of 4)
Re: Replacing a keyword with another one in the keyword list
OK, here you go:

exiftool -if "$keywords =~ /\bB\b/i" -keywords-=B -keywords+=D DIR

Use double quotes as above in Windows, or single quotes with other operating systems. The "i" after the regular expression does a case-insensitive test, so you should remove it if you want case sensitivity. The two "\b" in the expression match at word boundaries.

- Phil
Write a response