mirror of
https://github.com/suchmememanyskill/TegraExplorer.git
synced 2024-11-22 20:06:43 +00:00
missing ) goes brrrr
this isnt even a change to code i literally just forgot a ) at the end of a string
This commit is contained in:
parent
e4747b2344
commit
90ae8f3176
1 changed files with 4 additions and 4 deletions
|
@ -1,6 +1,6 @@
|
||||||
# Copyright (c) 2021 bleck9999
|
# Copyright (c) 2021 bleck9999
|
||||||
# https://github.com/bleck9999/ts-minifier
|
# https://github.com/bleck9999/ts-minifier
|
||||||
# Version: 1095d14a
|
# Version: c1b874bb
|
||||||
|
|
||||||
import argparse
|
import argparse
|
||||||
import itertools
|
import itertools
|
||||||
|
@ -181,15 +181,15 @@ def minify(script: Code, userobjects, usages):
|
||||||
userobjects[minName] = "TRN"
|
userobjects[minName] = "TRN"
|
||||||
break
|
break
|
||||||
if not minName:
|
if not minName:
|
||||||
print(f"{'Function' if otype == 'func' else 'Variable'} name {uo} could be shortened but no available "
|
print(f"{'Function' if otype == 'func' else 'Variable'} name {uo} could be shortened but "
|
||||||
f"names found (would save {uses} bytes)")
|
f"no available names found (would save {uses} bytes)")
|
||||||
continue
|
continue
|
||||||
# we assume that nobody is insane enough to exhaust all *2,808* 2 character names,
|
# we assume that nobody is insane enough to exhaust all *2,808* 2 character names,
|
||||||
# instead that uo is len 2 and all the 1 character names are in use (because of that we dont multiply
|
# instead that uo is len 2 and all the 1 character names are in use (because of that we dont multiply
|
||||||
# uses by anything as multiplying by a difference of 1 would be redundant)
|
# uses by anything as multiplying by a difference of 1 would be redundant)
|
||||||
if not auto_replace:
|
if not auto_replace:
|
||||||
print(f"{'Function' if otype == 'func' else 'Variable'} name {uo} could be shortened ({uo}->{minName}, "
|
print(f"{'Function' if otype == 'func' else 'Variable'} name {uo} could be shortened ({uo}->{minName}, "
|
||||||
f"would save {uses*(uolen - len(minName))} bytes")
|
f"would save {uses*(uolen - len(minName))} bytes)")
|
||||||
continue
|
continue
|
||||||
else:
|
else:
|
||||||
print(f"Renaming {'Function' if otype == 'func' else 'Variable'} {uo} to {minName} "
|
print(f"Renaming {'Function' if otype == 'func' else 'Variable'} {uo} to {minName} "
|
||||||
|
|
Loading…
Reference in a new issue