ExifTool > Developers

executing exiftool from AppleScript: why failing (Solved)

(1/1)

jaladuvar:
Hello I don't know if I post in the right forum, if not please advise me...

I've got an apple script which reads tags at different lines (all exiftool command lines return value in the terminal) but one returns nothing when run in Applescript do shell script why this ?
Line 1 : set the_list_items to do shell script "/usr/local/bin/exiftool -config .test_config.config -MyCritdates -s3 -t -d %Y%m%D-%H:%M:%s " & quoted form of unfile
retenus nothing when but returning this when run in terminal:

--- Code: ---20101120-02:58:22 20101120-02:58:22 20101120-02:58:22 20101120-09:58:21 20101120-09:58:21
--- End code ---

Line 2 :set old_date to do shell script "/usr/local/bin/exiftool -config .oldest_datetime_config.config -OldestDateTime -s " & quoted form of un_file
returns:
--- Code: ---2010:11:20 02:58:22
--- End code ---
same return in terminal
 The first config file was not in the proper directory, the second one was duplicated into different places... :-[

Phil Harvey:
It would be safest to specify a full path for the config file, eg:

/usr/local/bin/exiftool -config /Users/phil/.oldest_datetime_config.config ...

Then you don't have to worry about which working directory AppleScript is using.

- Phil

jaladuvar:
Thank you...I'll do that

Navigation

[0] Message Index

Go to full version