I just love exiftools - but at over 70 years of age sometimes i just get stuck :)
I have moved over 50,000 photos from Picasa to Onedrive and successfully created a batch file to do all the field changes, additions and deletions (for unnecessary fileds) so that it can be searched in OneDrive
I even have added in the directory name as the title
I still "manage" them on picassa as i find it best for people management
this all works extremely well
The batch is designed so that I can just drag a file or directory over it to run
Now, so that i dont have to update ALL photo files every time i update, I am trying to add in an opening line to the batch so that it only executes exiftools if the modifydate is after a certain date . below is what I have tried but failed (the 3rd line is my issue)
@echo off
exiftool -sep ;^
-if '$FileModifyDate gt "2022:10:14"'^
... then the executing lines such as below
"-xpkeywords<RegionName"^
"-xmp:regionpersondisplayname<RegionName"^
"-xmp:title<${directory;s(.*/)()}"^
-overwrite_original -m -r %1
pause
the batch file above is even running for files modified AFTER the date - so i am doing something wrong :(
Last edit: Tony Magnus 2022-10-15
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Hi
I just love exiftools - but at over 70 years of age sometimes i just get stuck :)
I have moved over 50,000 photos from Picasa to Onedrive and successfully created a batch file to do all the field changes, additions and deletions (for unnecessary fileds) so that it can be searched in OneDrive
I even have added in the directory name as the title
I still "manage" them on picassa as i find it best for people management
this all works extremely well
The batch is designed so that I can just drag a file or directory over it to run
Now, so that i dont have to update ALL photo files every time i update, I am trying to add in an opening line to the batch so that it only executes exiftools if the modifydate is after a certain date . below is what I have tried but failed (the 3rd line is my issue)
@echo off
exiftool -sep ;^
-if '$FileModifyDate gt "2022:10:14"'^
... then the executing lines such as below
"-xpkeywords<RegionName"^
"-xmp:regionpersondisplayname<RegionName"^
"-xmp:title<${directory;s(.*/)()}"^
-overwrite_original -m -r %1
pause
the batch file above is even running for files modified AFTER the date - so i am doing something wrong :(
Last edit: Tony Magnus 2022-10-15
If it's in a bat file, you probably have to use quoting for CMD, which would be double quotes on the outside, single quotes inside the argument.
-if "$FileModifyDate gt '2022:10:14' "
Powershell would need quoting as you currently have them. I think that would require a… ps1(?) file.
That did it. PERFECTLY in the batch file.
I thought I had tried that - but I hadnt left a space between the last ' and "
thanks from Australia
Last edit: Tony Magnus 2022-10-16
The space isn't necessary. I only included it to make it easier to see what was single quote and what was double quote.