Renaming my JPG files - still learning

Started by Archive, May 12, 2010, 08:54:34 AM

Previous topic - Next topic

Archive

[Originally posted by bdarnell on 2009-04-07 20:27:22-07]

here is my command string...but no files are renamed? using winxp sp3 , help please!

Code:
exiftool -d  %B%d_%Y%%-c.%%e "FileName<CreateDate" E:\Documents and Settings\bdarnell\My Documents\My Pictures\christmas\test.jpg

Archive

[Originally posted by exiftool on 2009-04-07 22:53:04-07]

Hi,

You are missing a "-" before the "FileName" argument.
Also, you probably need quotes around the file
name since it contains spaces:

Code:
exiftool -d  %B%d_%Y%%-c.%%e "-FileName<CreateDate" "E:\Documents and Settings\bdarnell\My Documents\My Pictures\christmas\test.jpg"

- Phil

Archive

[Originally posted by bdarnell on 2009-04-08 10:46:02-07]

Thanks Phil.  That was my missing link. =)  I have another question.  Can I replace the text "test.jpg" to "*.jpg" so that it replaces all the files in a directory?

Thanks again for your help,
Branson

Code:
exiftool -d  %B%d_%Y%%-c.%%e "-FileName<CreateDate" "E:\Documents and Settings\bdarnell\My Documents\My Pictures\christmas\*.jpg"

Archive

[Originally posted by exiftool on 2009-04-08 11:01:14-07]

Hi Branson,

The answer is "yes", but it is better to do it this way:

Code:
exiftool -d  %B%d_%Y%%-c.%%e "-FileName<CreateDate" -ext jpg "E:\Documents and Settings\bdarnell\My Document
+s\My Pictures\christmas\"

One advantage of this method (letting exiftool find the jpg
images for you) is that you can process images
in contained subdirectories just by adding the -r option.

- Phil

Archive

[Originally posted by bdarnell on 2009-04-08 11:01:31-07]

oh ya, there was another question i had for you.  I want to change the %%-c to not use a dash but surround the number with  ( ) because that is how winxp renames the files.  Here is the code i tried, but there is something missing from it too.

Thanks Phil

Code:
exiftool -d  %B%d_%Y%% (c).%%e "-FileName<CreateDate" "E:\Documents and Settings\bdarnell\My Documents\My Pictures\christmas\*.jpg"

-Branson

Archive

[Originally posted by exiftool on 2009-04-08 11:08:08-07]

Hi Branson,

See the -w option in the
https://exiftool.org/exiftool_pod.html" target="_blank">exiftool
application documentation for details about the %c
code.  But basically, you want to just drop the "-" in
"%%-c" if you don't want the "-" in the filename.

But it sounds like this probably won't do exactly what you want.
You can add brackets around the copy number, but there is no
way to write the brackets only if a copy number is written.

- Phil

Archive

[Originally posted by bdarnell on 2009-04-08 11:19:45-07]

thanks Phil,
I understand your reply completely, it would require a code rewrite in that section.  The good thing is that I program using Labview.  It is very versatile, but i can't get code to read the EXIF information.  Your tool is great because I parse information using my Labview program and pass it to your command line exiftool.  I will add code on my end to rename the files that contain a "-1" to "(1)"  Once I get this section done I should send you a copy if you'd like.

-Branson

Archive

[Originally posted by exiftool on 2009-04-08 14:47:58-07]

Hi Branson,

Sure, send me a copy once your code is finalized.
It may come in handy.  (We use LabView here too.)

Thanks.

- Phil