Skip to content

Instantly share code, notes, and snippets.

import re
from datetime import datetime
from datetime import timedelta
logFilePath = "debug.log"
outputFilePath = "output.csv"
with open(logFilePath, "r") as logFile, open(outputFilePath, "w") as csvFile:
lines = logFile.readlines()
csvFile.write("date,elapsed time,height\n")