-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathmain.py
More file actions
30 lines (23 loc) · 712 Bytes
/
main.py
File metadata and controls
30 lines (23 loc) · 712 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
import argparse
from decode_file import decompress, deserialize
from write_to_csv import write_to_csv
if __name__ == '__main__':
# Setup and read the command line arguments
parser = argparse.ArgumentParser(
description='Decompress & decode a ScoreSaber replay file'
)
parser.add_argument(
'-i',
'--input',
help='path to the file to parse',
default="replay.dat"
)
parser.add_argument(
'-o',
'--output',
help='path to the output folder',
default="output"
)
args = parser.parse_args()
# Parse the input and save it to the output file
write_to_csv(deserialize(decompress(args.input)), args.output)