-
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmain.py
37 lines (26 loc) · 1.07 KB
/
main.py
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
31
32
33
34
35
36
37
import helpers
import json
from api import API
from proxy import PROXY
helpers.disableWinConSole()
if helpers.checkFiles():
with open(helpers.files[0], 'r') as openfile:
CONFIG = json.loads(json.load(openfile))
helpers.debug = CONFIG['debug']
with open(helpers.files[1], 'r') as openfile:
CREDENTIALS = json.loads(json.load(openfile))
try:
with open(helpers.files[2], 'r') as openfile:
COOKIES = json.loads(json.load(openfile))
except:
COOKIES = ''
jambox = API(CREDENTIALS, COOKIES)
if(helpers.checkChannels()):
helpers.exportChannels(jambox, CONFIG['hls'])
if(helpers.checkList()):
helpers.exportList(CONFIG['host'], CONFIG['port'])
with open(helpers.channelsFile, 'r') as openfile:
channels = json.loads(openfile.read())
with open(helpers.files[2], 'r') as openfile:
COOKIES = json.loads(json.load(openfile))
PROXY(jambox, channels, CONFIG['host'], CONFIG['port'], CONFIG['threaded'], COOKIES, CONFIG['debug'])