diff options
author | emkael <emkael@tlen.pl> | 2017-06-07 02:26:12 +0200 |
---|---|---|
committer | emkael <emkael@tlen.pl> | 2017-06-07 02:26:12 +0200 |
commit | 8d8184da5eef77927d89b4380d5764527a5ccb8d (patch) | |
tree | 2ef6e4cd3243e4312f6892896895abcaf127db9d | |
parent | 742f0e753e3968d00ca795706dc622c41ab576a9 (diff) |
Helper script for converting Cezar ranking CSV to usable format
-rw-r--r-- | bin/convert-cezar-ranking-csv.py | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/bin/convert-cezar-ranking-csv.py b/bin/convert-cezar-ranking-csv.py new file mode 100644 index 0000000..4dcee92 --- /dev/null +++ b/bin/convert-cezar-ranking-csv.py @@ -0,0 +1,9 @@ +import csv, sys + +data = list(csv.reader(file(sys.argv[1]), delimiter=";")) + +output = csv.writer(file(sys.argv[2], 'w')) + +date = data[1][3] +for row in data[4:-1]: + output.writerow([row[0], date, row[2], row[1]]) |