[powermanga] update to new format
This commit is contained in:
@@ -14,22 +14,18 @@ import os.path
|
|||||||
import json
|
import json
|
||||||
import re
|
import re
|
||||||
|
|
||||||
info = {
|
class PowerMangaExtractor(Extractor):
|
||||||
"category": "powermanga",
|
|
||||||
"extractor": "PowerMangaExtractor",
|
category = "powermanga"
|
||||||
"directory": ["{category}", "{manga}", "c{chapter:>03}{chapter-minor} - {title}"],
|
directory_fmt = ["{category}", "{manga}", "c{chapter:>03}{chapter-minor} - {title}"]
|
||||||
"filename": "{manga}_c{chapter:>03}{chapter-minor}_{page:>03}.{extension}",
|
filename_fmt = "{manga}_c{chapter:>03}{chapter-minor}_{page:>03}.{extension}"
|
||||||
"pattern": [
|
pattern = [
|
||||||
(r"(?:https?://)?read(?:er)?\.powermanga\.org/read/"
|
(r"(?:https?://)?read(?:er)?\.powermanga\.org/read/"
|
||||||
r"(.+/([a-z]{2})/\d+/\d+)(?:/page)?"),
|
r"(.+/([a-z]{2})/\d+/\d+)(?:/page)?"),
|
||||||
],
|
]
|
||||||
}
|
|
||||||
|
|
||||||
class PowerMangaExtractor(Extractor):
|
|
||||||
|
|
||||||
def __init__(self, match):
|
def __init__(self, match):
|
||||||
Extractor.__init__(self)
|
Extractor.__init__(self)
|
||||||
self.category = info["category"]
|
|
||||||
self.part = match.group(1)
|
self.part = match.group(1)
|
||||||
self.lang = match.group(2)
|
self.lang = match.group(2)
|
||||||
extra = "er" if "://reader" in match.string else ""
|
extra = "er" if "://reader" in match.string else ""
|
||||||
|
|||||||
Reference in New Issue
Block a user