How can I strip the first 4 characters, add a 6 digit substring and add a suffix at the same time?
All of the concerning filenames have the same format, for example: IMG-20160523-WA0006.jpg
The format I need is: 20160523140000-WA0006_received.jpg
I came not further than this:
exiftool '-TestName<${FileName;s/IMG-(\d{8})-([A-Za-z]+)(\d{4}).*/$1-$2$3_received/}.%e'
The regular expression will not match anymore if "140000" is added:
exiftool '-TestName<${FileName;s/IMG-(\d{8})-([A-Za-z]+)(\d{4}).*/$1140000-$2$3_received/}.%e'
Is it possible to add this substring some way? Thanks in advance.
- Fulco
Use ${1}140000 instead.
Thank you! I really appreciate your help.
- Fulco