John Coyle wrote:

Just a friendly warning.  You have to be a bit careful with the rename
command in DOS/Windows.  The lengths of the old and new file names must
be the same.

> "rename IMG?????.jpg IMGK????.jpg"

Thus the need for five ? characters in the old name and four in the new
name in this command.

> To be really flexible, write yourself a little batch file containing this 
> one line:
> rename  %1?????.%2 %1%3????.%4
> Save it: I called mine Prename.bat.  To ensure you can use it always, save 
> it to your Windows or WINNT folder.

For this to work, the old file names must all have the same prefix
("%1", e.g., "IMG"), they must have five characters following that
prefix, and they must be unique within the rightmost four characters
before the filename extension ("%2" or "%4").  Plus, that "%4" should be
replaced with "%2" or the file names won't match the format of the data
inside them.  So it could drop %4 completely and just use

rename %1?????.%2 %1%3????.%2

Now all of this will typically hold for the old file names as created by
the camera.  Unfortunately, it imposes itself on the new file names,
too, which restricts your naming conventions pretty severely.

For example, as everyone, my images from the camera start out as
"IMGPnnnn.PEF" or "IMGPnnnn.JPG".  But my naming conventions need more
space than four characters.  For example, the shots from the 2003 Petit
le Mans would be named "PlM03-nnnn.PEF".

For film, there's also a marker in the name for which film roll it was,
like "PlM03-04-nn.TIFF" (after scanning).  Before the MZ-S, that would
just be a sequential number from 01 through the number of rolls I shot
at the event.  Plus I'd shoot a "registration frame" at the beginning of
each roll of an index card with the event name, date, and roll number so
I could sort the rolls out after taking them in for processing.

With the MZ-S I changed to using the "roll serial number" that the MZ-S
burned onto the leader.  I also dropped the "registration frames"
because the "roll serial number" identified their order.

After some serious efforts over a /long/ period of time, I've been
unable to convince the built-in rename command to do any lengthening of
the new name.

-- 
Thanks,
DougF (KG4LMZ)

-- 
PDML Pentax-Discuss Mail List
[email protected]
http://pdml.net/mailman/listinfo/pdml_pdml.net

Reply via email to