Search

4/02/2013

exiftool

exiftool - almost same with dropbox: exiftool '-FileName<CreateDate' -d "%Y-%m-%d %H.%M.%S%%-c.%%e" .

exiftool -filename=new.jpg dir/old.jpg Rename "old.jpg" to "new.jpg" in directory "dir". exiftool -directory=%e dir Move all files from directory "dir" into directories named by the original file extensions. exiftool '-Directory<DateTimeOriginal' -d %Y/%m/%d dir Move all files in "dir" into a directory hierarchy based on year, month and day of "DateTimeOriginal". ie) This command would move the file "dir/image.jpg" with a "DateTimeOriginal" of "2005:10:12 16:05:56" to "2005/10/12/image.jpg". exiftool -o . '-Directory<DateTimeOriginal' -d %Y/%m/%d dir Same effect as above except files are copied instead of moved. exiftool '-filename<%f_${focallength}.%e' dir Rename all files in "dir" by adding FocalLength to the file name. exiftool '-FileName<CreateDate' -d %Y%m%d_%H%M%S%%-c.%%e dir Rename all images in "dir" according to the "CreateDate" date and time, adding a copy number with leading '-' if the file already exists ("%-c"), and preserving the original file extension (%e). Note the extra '%' necessary to escape the filename codes (%c and %e) in the date format string. exiftool -r '-FileName<CreateDate' -d %Y-%m-%d/%H%M_%%f.%%e dir Both the directory and the filename may be changed together via the "FileName" tag if the new "FileName" contains a '/'. The example above recursively renames all images in a directory by adding a "CreateDate" timestamp to the start of the filename, then moves them into new directories named by date. exiftool '-FileName<${CreateDate}_$filenumber.jpg' -d %Y%m%d *.jpg Set the filename of all JPG images in the current directory from the CreateDate and FileNumber tags, in the form "20060507_118-1861.jpg".

沒有留言: