A quick question... (Edited)
jhead -n%Y%m%d [(name)] 001 .jpg
(Not sure which options lets me create a filename after the year/month/day option in the usage documentation)
If it matters, I'm using a Mac.
Photography Stack Exchange is a question and answer site for professional, enthusiast and amateur photographers. It only takes a minute to sign up.Sign up to join this community
I want to overwriting more than one image and a number count “001”, “002” ect.
For the example you provided in a comment to tfb's answer, sequentializing the filenames breaks when you use the
%f option. With multiple input files you'd get:
$ ls *.jpg foo.jpg foo2.jpg $ jhead -n"%Y_%m_%d-%f-newname001" *.jpg foo.jpg --> 2019_09_14-foo-newname001.jpg foo2.jpg --> 2019_09_14-foo2-newname001.jpg
But if you omit
%f, and add
%03i, you'll get the following:
$ ls *.jpg foo.jpg foo2.jpg $ jhead -n"%Y_%m_%d-newname-%03i" *.jpg foo.jpg --> 2019_09_14-newname-001.jpg foo2.jpg --> 2019_09_14-newname-002.jpg
I'm not quite sure what you're after, but:
$ ls *.jpg foo.jpg $ jhead -n"%Y%m%d%H%M-%f-renamed" foo.jpg foo.jpg --> 201909141339-foo-renamed.jpg $ ls *.jpg 201909141339-foo-renamed.jpg
The usage documentation for
jhead is quite good, and you might want to check the manual for
strftime (if you're on a Unixoid system, which it looks like you are), which is where all of the time-and-date formatting stuff comes from. But note that
jhead has some additional options, such as
%f that I used above.