- May
- 62
- 1
Code:
[D:\TMP] dir /b /a-d *-*
a-b
a-b--c---d
a--b-c
a-b-c-d
ren ::- ::_
But what if I want to convert the dashes to spaces?I haven't figured out how to include a space character that is recognized as other than an empty string (or, literally. the characters I've typed in). I've tried space, quoted space, \x20, \040, \o{40}.
I'm using Perl REs.
Hmm. I did find a way to do it. Pretty dorky. If you know a better solution, let me know.
Code:
[D:\TMP] ren ::- ":: StringNotInAnyFileName"
[D:\TMP] ren ::StringNotInAnyFileName ::