Files
startrek-ml/FriendsConverter.py
Beppe Vanrolleghem 3fd04b3ffd why isn't it commiting
2018-05-22 21:58:56 +02:00

17 lines
430 B
Python

import sys
import json
file = sys.argv[1]
with open(file, "r") as infile:
script=infile.read().replace('\n', '\\n')
while (True):
if(script.find("[Scene:") == -1):
break
TestFromSceneOn = script[script.find("[Scene:"):]
tempEndOfScript= script[:script.find("[Scene:")]
print(tempEndOfScript)
script = TestFromSceneOn[script.find("[Scene:")+7:]
print("END OF TEST")
print(TestFromSceneOn)