I’m making an attempt to include an exiftool command into an Applescript routine that performs advanced picture manipulations. The next routine is geared toward modifying the creation dates and modification dates of the picture information moved to a listing after manipulation.
I wish to use the basic exiftool command:
exiftool "-filemodifydate<datetimeoriginal" "-filecreatedate<datetimeoriginal" DIR
Nevertheless the listing is known as by the script with the command :
set pTargetFoldername to "Edited-pictures" & house & date string of (present date) & house & time of (present date) as string
.
And due to this fact the listing identify accommodates areas.
My routine AdjustDates
doesn’t work. The ensuing command doesn’t compensate for the areas and can’t be utilized in a “do shell script cmd” name The command created (with the dates within the native french language) is :
"/usr/native/bin/exiftool -filemodifydate<datetimeoriginal -filecreatedate<datetimeoriginal '/Customers/yves/Desktop/Edited-Footage mercredi 31 juillet 2024 70545'"
I don’t appear to see an answer which ought to appear trivial.
on AdjustDates(pTargetFolderPath)
inform software "Finder"
set ThePath to (POSIX path of pTargetFolderPath)
finish inform
set exiftool_path to "/usr/native/bin/exiftool"
set exiftool_args to "-filemodifydate<datetimeoriginal" & house & "-filecreatedate<datetimeoriginal"
set cmd to exiftool_path & house & exiftool_args & house & (quoted type of ThePath)
return cmd --for check solely
--do shell script cmd -- not useful as a result of areas within the listing path
finish AdjustDates