From e932c7e1ec526ec7dcded8336f379cc8c43bb450 Mon Sep 17 00:00:00 2001 From: TheMaverickProgrammer <91709+TheMaverickProgrammer@users.noreply.github.com> Date: Sat, 25 Jan 2020 17:17:34 -0600 Subject: [PATCH 1/2] Update split.py now works with legacy Python ( < 3.0) --- split.py | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/split.py b/split.py index da97b37..6b26b00 100644 --- a/split.py +++ b/split.py @@ -2,10 +2,17 @@ import os border = '// ----------------------------------------------------------------------------' +PythonVersion = sys.version_info[0]; + with open('httplib.h') as f: lines = f.readlines() inImplementation = False - os.makedirs('out', exist_ok=True) + + if PythonVersion < 3: + os.makedirs('out') + else: + os.makedirs('out', exist_ok=True) + with open('out/httplib.h', 'w') as fh: with open('out/httplib.cc', 'w') as fc: fc.write('#include "httplib.h"\n') From a7a6df49a4afa69e172cc466fc22c339704ce426 Mon Sep 17 00:00:00 2001 From: TheMaverickProgrammer <91709+TheMaverickProgrammer@users.noreply.github.com> Date: Sat, 25 Jan 2020 17:19:15 -0600 Subject: [PATCH 2/2] Update split.py --- split.py | 1 + 1 file changed, 1 insertion(+) diff --git a/split.py b/split.py index 6b26b00..3bd0121 100644 --- a/split.py +++ b/split.py @@ -1,4 +1,5 @@ import os +import sys border = '// ----------------------------------------------------------------------------'