Page 1 of 1

Trying to normalize pattern with date and rest of filename

PostPosted: Wed Nov 10, 2021 4:48 am
by Wirsing84
Hi guys & gals,

I have lots of files named like this:
2019-09-19_some-weird__file_name.pdf

What I want to achieve:
2019-09-19--some-weird__file_name.pdf

This is what I tried:
if
Name -> does not match -> (o Date Pattern)--(...)
then
Rename -> with pattern -> (o Date Pattern)--(name)(extension)

However this is the result:
--2019-09-19_some-weird__file_name.pdf

I was expecting the Date Pattern to be matched and "extracted" from name, and the remainder of name to be available within (name), but that does not seem to be how it works...

Please help :)
Thx!!
Chris

Re: Trying to normalize pattern with date and rest of filena

PostPosted: Wed Nov 10, 2021 2:52 pm
by Mr_Noodle
Don't you want _ in the match patterns and not --? Also, you need another custom attribute to grab the second part. (name) is the whole name including the date. If you only want that end part, you need to capture that into a custom attribute by itself.