diff options
author | Walter Purcaro <vuolter@users.noreply.github.com> | 2015-04-08 03:37:42 +0200 |
---|---|---|
committer | Walter Purcaro <vuolter@users.noreply.github.com> | 2015-04-08 03:37:42 +0200 |
commit | a667e20cfc029672801f28e6db3b05483658c13d (patch) | |
tree | 86ac4d28b7a3511f5dbb14b22da86c6cb9ff852d /module/plugins/hoster/RemixshareCom.py | |
parent | [SolidfilesCom] Cleanup (diff) | |
download | pyload-a667e20cfc029672801f28e6db3b05483658c13d.tar.xz |
[RemixshareCom] Cleanup
Diffstat (limited to 'module/plugins/hoster/RemixshareCom.py')
-rw-r--r-- | module/plugins/hoster/RemixshareCom.py | 30 |
1 files changed, 12 insertions, 18 deletions
diff --git a/module/plugins/hoster/RemixshareCom.py b/module/plugins/hoster/RemixshareCom.py index b62db8af3..d60101aed 100644 --- a/module/plugins/hoster/RemixshareCom.py +++ b/module/plugins/hoster/RemixshareCom.py @@ -16,23 +16,25 @@ from module.plugins.internal.SimpleHoster import SimpleHoster, create_getInfo class RemixshareCom(SimpleHoster): __name__ = "RemixshareCom" __type__ = "hoster" - __version__ = "0.04" + __version__ = "0.05" __pattern__ = r'https?://remixshare\.com/(download|dl)/\w+' __config__ = [("use_premium", "bool", "Use premium account if available", True)] __description__ = """Remixshare.com hoster plugin""" __license__ = "GPLv3" - __authors__ = [("zapp-brannigan", "fuerst.reinje@web.de"), - ("Walter Purcaro", "vuolter@gmail.com"), - ("sraedler", "simon.raedler@yahoo.de")] + __authors__ = [("zapp-brannigan", "fuerst.reinje@web.de" ), + ("Walter Purcaro", "vuolter@gmail.com" ), + ("sraedler" , "simon.raedler@yahoo.de")] - INFO_PATTERN = r'title=\'.+?\'>(?P<N>.+?)</span><span class=\'light2\'> \((?P<S>\d+) (?P<U>[\w^_]+)\)<' - OFFLINE_PATTERN = r'<h1>Ooops!<' + INFO_PATTERN = r'title=\'.+?\'>(?P<N>.+?)</span><span class=\'light2\'> \((?P<S>\d+) (?P<U>[\w^_]+)\)<' + HASHSUM_PATTERN = r'>(?P<T>MD5): (?P<H>\w+)' + OFFLINE_PATTERN = r'<h1>Ooops!' - LINK_FREE_PATTERN = r'(http:\/\/remixshare\.com\/startloading(\w|\/)+)' + LINK_PATTERN = r'var uri = "(.+?)"' TOKEN_PATTERN = r'var acc = (\d+)' + WAIT_PATTERN = r'var XYZ = "(\d+)"' @@ -42,23 +44,15 @@ class RemixshareCom(SimpleHoster): def handleFree(self, pyfile): - b = re.search(self.LINK_FREE_PATTERN, self.html) + b = re.search(self.LINK_PATTERN, self.html) if not b: - self.error(_("Cannot parse download url")) + self.error(_("File url")) c = re.search(self.TOKEN_PATTERN, self.html) if not c: - self.error(_("Cannot parse file token")) + self.error(_("File token")) self.link = b.group(1) + "/zzz/" + c.group(1) - self.logDebug(self.link) - - #Check if we have to wait - seconds = re.search(self.WAIT_PATTERN, self.html) - if seconds: - self.logDebug("Wait " + seconds.group(1) + " Seconds") - self.wait(seconds.group(1)) - self.download(self.link) getInfo = create_getInfo(RemixshareCom) |