You've already forked pokecrystal-board
mirror of
https://gitlab.com/xCrystal/pokecrystal-board.git
synced 2025-09-08 08:13:02 -07:00
for/write → writelines
This commit is contained in:
@@ -25,7 +25,7 @@ def total_bank_size(type):
|
|||||||
}
|
}
|
||||||
return sizes[type]
|
return sizes[type]
|
||||||
|
|
||||||
def sorted_mapfile(input):
|
def map_to_sym(input):
|
||||||
# analogous to ";File generated by rgblink"
|
# analogous to ";File generated by rgblink"
|
||||||
yield ';File generated by sort_map.py\n'
|
yield ';File generated by sort_map.py\n'
|
||||||
|
|
||||||
@@ -117,10 +117,9 @@ def main():
|
|||||||
output_filename = sys.argv[2]
|
output_filename = sys.argv[2]
|
||||||
with open(input_filename, 'r') as infile:
|
with open(input_filename, 'r') as infile:
|
||||||
input = infile.readlines()
|
input = infile.readlines()
|
||||||
output = sorted_mapfile(input)
|
output = map_to_sym(input)
|
||||||
with open(output_filename, 'w') as outfile:
|
with open(output_filename, 'w') as outfile:
|
||||||
for line in output:
|
outfile.writelines(output)
|
||||||
outfile.write(line)
|
|
||||||
|
|
||||||
if __name__ == '__main__':
|
if __name__ == '__main__':
|
||||||
main()
|
main()
|
||||||
|
Reference in New Issue
Block a user