Renaming/numbering files in date modified order

Questions about other topics - please check if your question fits better in another category before posting here
Forum rules
Before you post please read how to get help
Post Reply
iain_33
Level 2
Level 2
Posts: 75
Joined: Sat Dec 22, 2018 11:29 am
Location: UK

Renaming/numbering files in date modified order

Post by iain_33 » Sat Mar 09, 2019 1:19 pm

In its infinite wisdom, my camera sometimes resets its file numbering without me knowing, and when I come to download them onto my PC, I end up with a series of photos numbered DSC_5123, DSC_5124, DSC_0001, DSC_0002, etc. If there's already photos with those numbers I'll end up with DSC_0001 (1).JPG, DSC_0001 (2).JPG and so on. The result is my photos end up in the wrong order since folders and slideshows list them by filename order. I know it's simple to click the "date modified" column in a folder to re-order them, but I'd like to re-number them so they stay in the right order.

Is there a way to renumber files in the date modified order, or even better, the date/time taken from the EXIF data? (date modified will be OK since I can do this before editing them)
Linux Mint 19.1 MATE (64 bit) on a HP G70 laptop (circa 2008)
Intel Pentium Dual Core T3400 @ 2.16GHz -- 3GB RAM -- 1TB HDD
Intel Mobile 4 Series graphics -- Intel 82801I audio
Atheros AR242x/AR542x wireless network adapter

User avatar
phd21
Level 19
Level 19
Posts: 9517
Joined: Thu Jan 09, 2014 9:42 pm
Location: Florida

Re: Renaming/numbering files in date modified order

Post by phd21 » Sat Mar 09, 2019 2:00 pm

Hi iain_33,

Off the top of my head, these applications come to mind:

You may want to look in the "Synaptic Package Manager (SPM)" for these applications, right-click to install them and to select any recommended and or suggested packages that you may also want, and for "exif" and "exiv2" packages.

Note: You may have to run a renaming twice or more to get exactly what you want. Example: first to add the exif date and time in the front of the filename (provides auto sort by name which is now a date) and again with those renamed files for renumbering. In Krename, if you select one of the exif functions and its value does not immediately show underneath in the rename column, erase that one and try another one.

Tip: when experimenting with renaming, make a copy of the files, or choose copy new renamed files to different folder location

"Krename" - my favorite renaming application.

"Gwenrename"

"XnViewMP" - go to their website, scroll down to download their Linux deb file and double-click it to install it.
XnViewMP · Multi-Platform Photo Viewer, Image Resizer and Batch Converter
https://www.xnview.com/en/xnviewmp/

Previous posts:

[SOLVED] Bulk Rename Help, Please - Linux Mint Forums
viewtopic.php?f=18&t=268215&hilit=gwenrename

[SOLVED] bulk rename with nemo - Linux Mint Forums
viewtopic.php?f=90&t=279848&hilit=gwenrename

List photos by "Date Taken" [SOLVED] - Linux Mint Forums
viewtopic.php?f=47&t=209742&hilit=gwenrename

Hope this helps ...
.
Krename tab 2 destination options
Krename tab 2 destination options
.
Krename tab 4 filename options
Krename tab 4 filename options
.
XnViewMP - batch renaming
XnViewMP - batch renaming
Phd21: Mint 19.2 Cinnamon & xKDE (Xfce) & KDE Neon 64-bit Awesome OS's, Ancient Dell OptiPlex 780 Core2Duo E8400 3GHz,4gb Ram, 256gb SDD, only Intel 4 Graphics. Why I use KDE?:https://opensource.com/life/15/4/9-reasons-to-use-kde

iain_33
Level 2
Level 2
Posts: 75
Joined: Sat Dec 22, 2018 11:29 am
Location: UK

Re: Renaming/numbering files in date modified order

Post by iain_33 » Sat Mar 09, 2019 3:05 pm

I can do it in Xnview MP? Excellent, I use that for organising my photos, I hadn't spotted that it did batch renaming too. Thanks for the tip!
Linux Mint 19.1 MATE (64 bit) on a HP G70 laptop (circa 2008)
Intel Pentium Dual Core T3400 @ 2.16GHz -- 3GB RAM -- 1TB HDD
Intel Mobile 4 Series graphics -- Intel 82801I audio
Atheros AR242x/AR542x wireless network adapter

User avatar
phd21
Level 19
Level 19
Posts: 9517
Joined: Thu Jan 09, 2014 9:42 pm
Location: Florida

Re: Renaming/numbering files in date modified order

Post by phd21 » Sat Mar 09, 2019 3:07 pm

Hi iain_33,

You are welcome...

Yes, you can use the superb XNViewMP although I have not used their batch renaming before.
Tutorial
https://www.xnview.com/download/XnViewM ... inners.pdf
.
XnViewMP - batch renaming
XnViewMP - batch renaming
Phd21: Mint 19.2 Cinnamon & xKDE (Xfce) & KDE Neon 64-bit Awesome OS's, Ancient Dell OptiPlex 780 Core2Duo E8400 3GHz,4gb Ram, 256gb SDD, only Intel 4 Graphics. Why I use KDE?:https://opensource.com/life/15/4/9-reasons-to-use-kde

iain_33
Level 2
Level 2
Posts: 75
Joined: Sat Dec 22, 2018 11:29 am
Location: UK

Re: Renaming/numbering files in date modified order

Post by iain_33 » Sat Mar 09, 2019 4:04 pm

Thanks also for the link to the beginner's guide, especially as it has a link within to an even more comprehensive user guide - I'd looked on Xnview's website for guides/instructions but all I could find was the forum.
Linux Mint 19.1 MATE (64 bit) on a HP G70 laptop (circa 2008)
Intel Pentium Dual Core T3400 @ 2.16GHz -- 3GB RAM -- 1TB HDD
Intel Mobile 4 Series graphics -- Intel 82801I audio
Atheros AR242x/AR542x wireless network adapter

Post Reply

Return to “Other topics”