inconsistent results ?

Started by simonmcnair, January 08, 2024, 07:44:25 AM

Previous topic - Next topic

simonmcnair

I can't see why the second command succeeds, whilst the first fails.  They are all jpg files.

Ideas please ?

exiftool -if "defined $XMP:LastKeywordXMP" -XMP:LastKeywordXMP= -overwrite_original -P -r -ext jpg "Z:\Pics\"
    1 directories scanned
  46 files failed condition
    0 image files read
exiftool -if "defined $XMP:LastKeywordXMP" -XMP:LastKeywordXMP= -overwrite_original -P -r -ext jpg "Z:\Pics\*.jpg"
  46 image files updated

Phil Harvey

I seem to remember something in Windows where a trailing backslash messes with the closing quote, but I don't know how this would result in the symptoms you are seeing.  Anyway, try "Z:\Pics" instead of "Z:\Pics\" to see if this does anything.

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

StarGeek

That is correct. The backslash is escaping the double quote. Either remove the trailing slash "Z:\Pics" or double it "Z:\Pics\\"
* Did you read FAQ #3 and use the command listed there?
* Please use the Code button for exiftool code/output.
 
* Please include your OS, Exiftool version, and type of file you're processing (MP4, JPG, etc).