|
|
@@ -3,6 +3,7 @@ from getpass import getpass
|
|
|
import requests
|
|
|
from html.parser import HTMLParser
|
|
|
from html.entities import name2codepoint
|
|
|
+from subprocess import call
|
|
|
|
|
|
def main():
|
|
|
while True:
|
|
|
@@ -45,7 +46,16 @@ def episode_test():
|
|
|
f.close()
|
|
|
epars = episodeParser()
|
|
|
epars.feed(str(content))
|
|
|
-
|
|
|
+ code = epars.code
|
|
|
+ link = "https://s3-psc.proxer.me/files/0/"+code+"/video.mp4"
|
|
|
+ print(link)
|
|
|
+ print('1 - open with vlc')
|
|
|
+ print('2 - download')
|
|
|
+ uin = input('$>: ')
|
|
|
+ if uin == '1':
|
|
|
+ call(["vlc", link])
|
|
|
+ if uin == '2':
|
|
|
+ call(['curl',link,'-o','test.mp4'])
|
|
|
|
|
|
def LesezeichenAll(sess):
|
|
|
response = sess.get('https://proxer.me/ucp?s=reminder&utm_source=nav#top')
|
|
|
@@ -116,6 +126,7 @@ def LesezeichenD():
|
|
|
|
|
|
class episodeParser(HTMLParser):
|
|
|
inScript = False
|
|
|
+ code = ""
|
|
|
|
|
|
def handle_starttag(self, tag, attrs):
|
|
|
if tag == 'script':
|
|
|
@@ -135,6 +146,7 @@ class episodeParser(HTMLParser):
|
|
|
code = streams[0][codeStart:]
|
|
|
code = code[:code.index('"')]
|
|
|
print(code)
|
|
|
+ self.code = code
|
|
|
|
|
|
def handle_endtag(self, tag):
|
|
|
if tag == 'script' and self.inScript:
|