microsoft / PowerToys

Windows system utilities to maximize productivity
MIT License
111.9k stars 6.59k forks source link

PowerRename: Variable not Working? #8940

Open Windowsuser1-bit opened 3 years ago

Windowsuser1-bit commented 3 years ago

Hello! Is there any difference between the two regex variables? Because in the overview section of PowerRename, the description for the first picture below would be "Appends ".txt" extension to existing file name" while in the second picture below, it would "Appends ".txt" extension to existing file name only if it does not have an extension." Thank you.

Screenshots

image

image

Jay-o-Way commented 3 years ago

Indeed. The combination seems to be invalid - for this purpose anyway. Using either part alone in Search, or using $1.txt in the Replace works, but only if there are no special characters (like +-#& and so on) in the filename. Seems like a bad example all together?