I'm trying to add a space before every capital letter, except the first one.
Here's what I have so far, and the output I'm getting:
>>> tex = "ThisFileName.txt"
>>> re.sub('[A-Z].', ' ', tex)
' his ile ame.txt'
I want: 'This File Name.txt'
(It'd be nice if I could also get rid of .txt, but I can do that in a separate operation.)