MOV files rename with creation date

Started by MichiMuc, June 10, 2012, 05:25:18 AM

Previous topic - Next topic

MichiMuc

hi everybody,

i´m sorry, but i can´t understand the answers already given to this problem.

can somebody please help me and solve my problem from the beginning?

i only want to change the file name of mov-files created with an iphone.

the files are at: "D:\Eigene Dateien\Eigene Bilder\Temp"
an should become a name like: year-month-day--hourMinuteSecond, eg. 12-05-01--153012

is there a change to get this working with an bat-file or anything like that? i tried the exifdropper und exiftoolgui already, but wasn´t succesful.

i´m sorry about my bad english.


thanks,
michael

Phil Harvey

Hi Michael,

With exiftool installed for command-line use, you can do this by creating a .BAT file containing this command:

exiftool -d "%%y-%%m-%%d--%%H%%M%%S" "-filename<createdate" -k %*

Then drag and drop your files and/or folders containing your files onto the .BAT file to rename the files.

The -k option keeps the exiftool window from disappearing when the command is done. 

Note that this will only work if the files contain a CreateDate tag.  If they don't, use exiftool -s -time:all FILE to see what date/time tags are available, and use one of these instead.

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

MichiMuc

Great! Thanks!

only one problem, i have to modify the time, because the time-stamp of the original is in GMT and at berlin we have GMT+2 or +1.

Is there a chance?


MichiMuc

and one more problem. the extension ".mov" gets lost.

e.g. "abcde.mov" becomes "12-06-09--155938" (but without .mov)

Phil Harvey

Oops, right.  Add .%%%%e to the end of the format string to include the file extension.

And you can set the QuickTimeUTC flag in a config file to force the QuickTime time tags to be converted from UTC:

# Specify default ExifTool option values
%Image::ExifTool::UserDefined::Options = (
    QuickTimeUTC => 1,  # assume QuickTime date/time values are in UTC
);


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

MichiMuc

#5
thanks...

it works! great!

Southdakotaguy

Great topic! It also solved my similar problem ...

MichiMuc

Hi Phil,

would be great if you could help another time. I use your script for my *.mov- and *.jpg-files.

Now there is a problem if there are 2 or more jpg´s created at the same time because the file name is used already. Do you think there is a possibility to add an "-1" or something like that in this cases?

And is it possible that only *.mov- and *.jpg-files are renamed and no others (e.g. *.ini)?

Thanks,
Michael

Phil Harvey

Hi Michael,

Add %-c to the output file name to add a copy number with a leading dash if the file already exists.

Add -ext mov -ext jpg to the command to get exiftool to only process these types of files.

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

MichiMuc