[komikcast] update domain to 'komikcast.la'

This commit is contained in:
Mike Fährmann
2025-01-26 16:54:14 +01:00
parent 804fd048ef
commit d2164af63d
3 changed files with 19 additions and 15 deletions

View File

@@ -495,7 +495,7 @@ Consider all listed sites to potentially be NSFW.
</tr> </tr>
<tr> <tr>
<td>Komikcast</td> <td>Komikcast</td>
<td>https://komikcast.cz/</td> <td>https://komikcast.la/</td>
<td>Chapters, Manga</td> <td>Chapters, Manga</td>
<td></td> <td></td>
</tr> </tr>

View File

@@ -6,19 +6,20 @@
# it under the terms of the GNU General Public License version 2 as # it under the terms of the GNU General Public License version 2 as
# published by the Free Software Foundation. # published by the Free Software Foundation.
"""Extractors for https://komikcast.cz/""" """Extractors for https://komikcast.la/"""
from .common import ChapterExtractor, MangaExtractor from .common import ChapterExtractor, MangaExtractor
from .. import text from .. import text
import re import re
BASE_PATTERN = r"(?:https?://)?(?:www\.)?komikcast\.(?:cz|lol|site|mo?e|com)" BASE_PATTERN = (r"(?:https?://)?(?:www\.)?"
r"komikcast\.(?:la|cz|lol|site|mo?e|com)")
class KomikcastBase(): class KomikcastBase():
"""Base class for komikcast extractors""" """Base class for komikcast extractors"""
category = "komikcast" category = "komikcast"
root = "https://komikcast.cz" root = "https://komikcast.la"
@staticmethod @staticmethod
def parse_chapter_string(chapter_string, data=None): def parse_chapter_string(chapter_string, data=None):
@@ -48,7 +49,7 @@ class KomikcastBase():
class KomikcastChapterExtractor(KomikcastBase, ChapterExtractor): class KomikcastChapterExtractor(KomikcastBase, ChapterExtractor):
"""Extractor for komikcast manga chapters""" """Extractor for komikcast manga chapters"""
pattern = BASE_PATTERN + r"(/chapter/[^/?#]+/)" pattern = BASE_PATTERN + r"(/chapter/[^/?#]+/)"
example = "https://komikcast.cz/chapter/TITLE/" example = "https://komikcast.la/chapter/TITLE/"
def metadata(self, page): def metadata(self, page):
info = text.extr(page, "<title>", " - Komikcast<") info = text.extr(page, "<title>", " - Komikcast<")
@@ -68,7 +69,7 @@ class KomikcastMangaExtractor(KomikcastBase, MangaExtractor):
"""Extractor for komikcast manga""" """Extractor for komikcast manga"""
chapterclass = KomikcastChapterExtractor chapterclass = KomikcastChapterExtractor
pattern = BASE_PATTERN + r"(/(?:komik/)?[^/?#]+)/?$" pattern = BASE_PATTERN + r"(/(?:komik/)?[^/?#]+)/?$"
example = "https://komikcast.cz/komik/TITLE" example = "https://komikcast.la/komik/TITLE"
def chapters(self, page): def chapters(self, page):
results = [] results = []

View File

@@ -10,9 +10,8 @@ from gallery_dl.extractor import komikcast
__tests__ = ( __tests__ = (
{ {
"#url" : "https://komikcast.lol/chapter/apotheosis-chapter-02-2-bahasa-indonesia/", "#url" : "https://komikcast.lol/chapter/apotheosis-chapter-02-2-bahasa-indonesia/",
"#category": ("", "komikcast", "chapter"),
"#class" : komikcast.KomikcastChapterExtractor, "#class" : komikcast.KomikcastChapterExtractor,
"#pattern" : r"https://svr\d+\.imgkc\d+\.my\.id/wp-content/img/A/Apotheosis/002-2/\d{3}\.jpg", "#pattern" : r"https://svr?\d+\.imgkc\d+\.my\.id/wp-content/img/A/Apotheosis/002-2/\d{3}\.jpg",
"#count" : 18, "#count" : 18,
"chapter" : 2, "chapter" : 2,
@@ -29,34 +28,39 @@ __tests__ = (
{ {
"#url" : "https://komikcast.site/chapter/apotheosis-chapter-02-2-bahasa-indonesia/", "#url" : "https://komikcast.site/chapter/apotheosis-chapter-02-2-bahasa-indonesia/",
"#category": ("", "komikcast", "chapter"),
"#class" : komikcast.KomikcastChapterExtractor, "#class" : komikcast.KomikcastChapterExtractor,
}, },
{ {
"#url" : "https://komikcast.me/chapter/apotheosis-chapter-02-2-bahasa-indonesia/", "#url" : "https://komikcast.me/chapter/apotheosis-chapter-02-2-bahasa-indonesia/",
"#category": ("", "komikcast", "chapter"),
"#class" : komikcast.KomikcastChapterExtractor, "#class" : komikcast.KomikcastChapterExtractor,
}, },
{ {
"#url" : "https://komikcast.com/chapter/apotheosis-chapter-02-2-bahasa-indonesia/", "#url" : "https://komikcast.com/chapter/apotheosis-chapter-02-2-bahasa-indonesia/",
"#category": ("", "komikcast", "chapter"), "#class" : komikcast.KomikcastChapterExtractor,
},
{
"#url" : "https://komikcast.cz/chapter/apotheosis-chapter-02-2-bahasa-indonesia/",
"#class" : komikcast.KomikcastChapterExtractor,
},
{
"#url" : "https://komikcast.la/chapter/apotheosis-chapter-02-2-bahasa-indonesia/",
"#class" : komikcast.KomikcastChapterExtractor, "#class" : komikcast.KomikcastChapterExtractor,
}, },
{ {
"#url" : "https://komikcast.me/chapter/soul-land-ii-chapter-300-1-bahasa-indonesia/", "#url" : "https://komikcast.me/chapter/soul-land-ii-chapter-300-1-bahasa-indonesia/",
"#category": ("", "komikcast", "chapter"),
"#class" : komikcast.KomikcastChapterExtractor, "#class" : komikcast.KomikcastChapterExtractor,
"#pattern" : r"https://svr\d\.imgkc\d*\.my\.id/wp-content/img/S/Soul_Land_II/300\.1/\d\d\.jpg", "#pattern" : r"https://svr?\d\.imgkc\d*\.my\.id/wp-content/img/S/Soul_Land_II/300\.1/\d\d\.jpg",
"#count" : 9, "#count" : 9,
"#sha1_metadata": "cb646cfed3d45105bd645ab38b2e9f7d8c436436", "#sha1_metadata": "cb646cfed3d45105bd645ab38b2e9f7d8c436436",
}, },
{ {
"#url" : "https://komikcast.site/komik/090-eko-to-issho/", "#url" : "https://komikcast.site/komik/090-eko-to-issho/",
"#category": ("", "komikcast", "manga"),
"#class" : komikcast.KomikcastMangaExtractor, "#class" : komikcast.KomikcastMangaExtractor,
"#pattern" : komikcast.KomikcastChapterExtractor.pattern, "#pattern" : komikcast.KomikcastChapterExtractor.pattern,
"#count" : 12, "#count" : 12,
@@ -78,7 +82,6 @@ __tests__ = (
{ {
"#url" : "https://komikcast.me/tonari-no-kashiwagi-san/", "#url" : "https://komikcast.me/tonari-no-kashiwagi-san/",
"#category": ("", "komikcast", "manga"),
"#class" : komikcast.KomikcastMangaExtractor, "#class" : komikcast.KomikcastMangaExtractor,
}, },