mirror of
https://github.com/a2-4am/4cade.git
synced 2024-09-23 16:55:57 +00:00
15 lines
398 B
Python
15 lines
398 B
Python
|
#!/usr/bin/env python3
|
||
|
|
||
|
# usage:
|
||
|
# builddisplaynames.py < res/GAMES.CONF > build/GAMES.CONF.WITH.NAMES
|
||
|
|
||
|
import sys
|
||
|
|
||
|
for line in sys.stdin:
|
||
|
if "," not in line: continue
|
||
|
if line.startswith("#"): continue
|
||
|
if "=" not in line:
|
||
|
prefix, key = line.split(",")
|
||
|
line = prefix + "," + key.strip() + "=" + key.replace(".", " ").title().replace(" Ii", " II")
|
||
|
print(line, end="")
|