Skip to content
Snippets Groups Projects
raw_convert.py 427 B
Newer Older
"""
This converts the raw copy/paste from Confluence table
"""
year = 2020

fout = open(f"list_{year}.txt", "w")
count = 0
Yngve Levinsen's avatar
Yngve Levinsen committed
for line in open("orig.txt", "r"):
    if len(line.strip()):
        if "Date" in line:
            fout.write("# ")
Yngve Levinsen's avatar
Yngve Levinsen committed
        fout.write(line[:-1])
        count += 1
Yngve Levinsen's avatar
Yngve Levinsen committed
    elif len(line) == 1:
        continue
    else:
        fout.write("  ")
    if count > 3:
        fout.write("\n")
        count = 0