aboutsummaryrefslogtreecommitdiff
path: root/tools/scripts/memsort.py
diff options
context:
space:
mode:
authorRémi Verschelde2016-11-02 22:26:55 +0100
committerRémi Verschelde2016-11-02 22:26:55 +0100
commit561c1f17a12a42b8263ce7dd40d90e1e9633c1de (patch)
treeb150ac41d41bc8a7602a2098a6a135f34221164a /tools/scripts/memsort.py
parent7c92b401f1d51f1a474e4fb37480c8b626c9dd47 (diff)
downloadgodot-561c1f17a12a42b8263ce7dd40d90e1e9633c1de.tar.gz
godot-561c1f17a12a42b8263ce7dd40d90e1e9633c1de.tar.zst
godot-561c1f17a12a42b8263ce7dd40d90e1e9633c1de.zip
style: Start applying PEP8 to Python files, indentation issues
Done with `autopep8 --select=E1`, fixes: - E101 - Reindent all lines. - E112 - Fix under-indented comments. - E113 - Fix over-indented comments. - E115 - Fix under-indented comments. - E116 - Fix over-indented comments. - E121 - Fix a badly indented line. - E122 - Fix a badly indented line. - E123 - Fix a badly indented line. - E124 - Fix a badly indented line. - E125 - Fix indentation undistinguish from the next logical line. - E126 - Fix a badly indented line. - E127 - Fix a badly indented line. - E128 - Fix a badly indented line. - E129 - Fix a badly indented line.
Diffstat (limited to 'tools/scripts/memsort.py')
-rw-r--r--tools/scripts/memsort.py24
1 files changed, 12 insertions, 12 deletions
diff --git a/tools/scripts/memsort.py b/tools/scripts/memsort.py
index d2e4fe022..15b4e7a84 100644
--- a/tools/scripts/memsort.py
+++ b/tools/scripts/memsort.py
@@ -4,7 +4,7 @@ import sys
arg="memdump.txt"
if (len(sys.argv)>1):
- arg=sys.argv[1]
+ arg=sys.argv[1]
f = open(arg,"rb")
@@ -18,18 +18,18 @@ cnt={}
while(l!=""):
- s=l.split("-")
- amount = int(s[1])
- what=s[2]
- if (what in sum):
- sum[what]+=amount
- cnt[what]+=1
- else:
- sum[what]=amount
- cnt[what]=1
+ s=l.split("-")
+ amount = int(s[1])
+ what=s[2]
+ if (what in sum):
+ sum[what]+=amount
+ cnt[what]+=1
+ else:
+ sum[what]=amount
+ cnt[what]=1
- l=f.readline()
+ l=f.readline()
for x in sum:
- print(x.strip()+"("+str(cnt[x])+"):\n: "+str(sum[x]))
+ print(x.strip()+"("+str(cnt[x])+"):\n: "+str(sum[x]))