Problem with FixNames plugin

  • This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn more.
#1
I have the following files:

==== begin paste
1C_Mihiro_043(1).zip
8=5Fm01=5FKortnie=5FO=92Connor=5F01.zip
=5FN=F6el=5FSimone=5F=28Marylan==Windows-1252Qd=29.zip
=Windows-1252Q200806=5FJuliette=5FFrett=E9=5F19.zip
=Windows-1252Q200806=5FJuliette=5FFrett=E9=5F25.zip
=windows-1252QAnnette_D=92Zam_=2818=29=2Ejpg=.zip
=Windows-1252Qcc=5FAnnette=5FD=92Zam=5F16xl.zip
=Windows-1252Qcc=5FAubrey=5FO=92Day=5F08xl.zip
=Windows-1252QNy=E1ri=5Fk=E9pek=5F1301=5F03.zip
=Windows-1252QNy=E1ri=5Fk=E9pek=5F1301=5F36.zip
=Windows-1252QNy=E1ri=5Fk=E9pek=5F1301=5F40.zip
=Windows-1252QPM200605=5FSabrina=5FPrei=DFer=5F30.zip
=Windows-1252Qugwp=5Fkatrin-h=E4nelt=5F01.zip
Bootylicious_&_Luscious_61.zip
com2Favatar2Fad516503a11cd5ca435acc9bb65235363Fs3D32&r=G.zip
Doutzen&Adriana04.zip
G-Granny&Friend.zip
GarcelleBeauvais(6).zip
MagdalenaSierka(5).zip
NatasaDilber(16).zip
ngary=5F09xl=5FVikt=F3ria=5FMetzk==Windows-1252Qer.zip
QFran=E7ois-Beneveniste=5F=28France=29=5F01214030=5F1.zip
ren=5FD=92Marie=5FPictorial==Windows-1252Q1=5F21xl.zip
SabrinaMarie(0).zip
theforbiddenfruitnicki'swordart'09.zip
theforbiddenfruitnicki'swordart'09_theforbiddenfruitnicki'swordart'09.ZIP
ws-1252Qcc=5FDian=92sBack!=5F13xl=5FDian=5FParkinson.zip
==== end paste

When I do fixnames /s *.* it doesn't fix any of these. What can I do please to fix &, ( and ), to _'s and =?? to their correct ascii charachters please?
 
#2
Hi,

just for interest - where do you get such horrible filenames from?

Frank
 

Charles Dye

Super Moderator
Staff member
May 20, 2008
3,415
40
Albuquerque, NM
prospero.unm.edu
#3
When I do fixnames /s *.* it doesn't fix any of these. What can I do please to fix &, ( and ), to _'s and =?? to their correct ascii charachters please?
It's not intended to; you can manipulate all of those characters easily in TCC. FixNames just replaces characters which you can't handle easily: percent signs, grave accents, carets....

I could add an option to decode =XX easily enough, but it would have to be an option and default to off. Sometimes a cigar is only a cigar....
 

Charles Dye

Super Moderator
Staff member
May 20, 2008
3,415
40
Albuquerque, NM
prospero.unm.edu
#5
Okay, I've put up a new build here: FixNames plugin

This one decodes =XX pairs when you specify /E. I've also added Windows-1252 support; if the decoded character is in the range 0x80 to 0x9f, you'll get a printable character instead of a C1 control char.
 
#6
Charles,

prompt> fixnames /E /N /s *.*

would adding to the Grand Total line something like:

"n files in x folders would be renamed."

then a similar line in each folder be possible please?
 
Aug 8, 2010
30
0
#7
Would it be too much trouble to have a switch to override "When a filename contains a percent sign followed by two hexadecimal digits, the trio is treated as an encoded character"? It would introduce an either/or condition for when you want %20 to become a space too, but sometimes brute force is a good thing.

I got your homage to Herr Freud. Nice.
 
Aug 8, 2010
30
0
#9
Sorry for the confusion. My interest is in a switch to not expand any %xx at all - perhaps treat the percent sign the same way as when it's followed by spaces.

From
PS and two spaces [% ].txt
To
PS and two spaces [_ ].txt

The "%20, either/or" connection in my last entry is that if FIXNAMES does "not expand any %xx at all" and there are legitimate %xx combinations (0x80 to 0x9f) and "rogue" combinations (>0x9F), it won't be possible to BOTH convert the legitimate ones AND just change the percent sign for the rogue ones. However, for the sake of the intention of the plugin, that would be preferred over creating characters like õ as happened once to me. More refinement than that would be nice, but not necessary.