Inconsistant spacing depending on end of the file name

Advanced Renamer forum
#1 : 16/09-22 06:32
Edward Eade II
Edward Eade II
Posts: 6
Replace Method
Text to be replaced: S(\d)(\d)E(\d)(\d)
Replace with: - s\1\2e\3\4 -

Source file = Text here s01e01 more text here.ext
Output file = Text here - s01e01 - more text here.ext

Source file = Text here s01e01 .ext
Output file = Text here - s01e01 -.ext

Note the trailing space disappeared in the second example, any way to fix this?


16/09-22 06:32
#2 : 19/09-22 20:09
L B
L B
Posts: 74
Reply to #1:
Honest question, in second example where the episode number is at the end of the file, why do you need trailing dashes and spaces after the episode number?


19/09-22 20:09
#3 : 25/09-22 14:20
David Lee
David Lee
Posts: 1125
Reply to #1:

The trailing space is retained when I reproduce your examples.

A neater way of adding the hyphens is:

Replace: "(S\d+E\d+)"
with: "- \1 -"


25/09-22 14:20