diff --git a/docs/supportedsites.rst b/docs/supportedsites.rst index 6a56476f..f47ed104 100644 --- a/docs/supportedsites.rst +++ b/docs/supportedsites.rst @@ -121,6 +121,7 @@ Imxto https://imx.to/ individual Images Pixhost https://pixhost.to/ individual Images Postimg https://postimages.org/ individual Images Turboimagehost https://www.turboimagehost.com/ individual Images +もえぴりあ https://vanilla-rock.com/ Posts, Tag-Searches ==================== =================================== ================================================== ================ .. |artstation-C| replace:: Images from Users, Albums, Artwork Listings, Challenges, individual Images, Likes, Search Results diff --git a/gallery_dl/extractor/__init__.py b/gallery_dl/extractor/__init__.py index dc3cee2e..81d480e2 100644 --- a/gallery_dl/extractor/__init__.py +++ b/gallery_dl/extractor/__init__.py @@ -93,6 +93,7 @@ modules = [ "tsumino", "tumblr", "twitter", + "vanillarock", "wallhaven", "warosu", "weibo", diff --git a/gallery_dl/extractor/vanillarock.py b/gallery_dl/extractor/vanillarock.py new file mode 100644 index 00000000..687ce3cf --- /dev/null +++ b/gallery_dl/extractor/vanillarock.py @@ -0,0 +1,95 @@ +# -*- coding: utf-8 -*- + +# Copyright 2019 Mike Fährmann +# +# This program is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License version 2 as +# published by the Free Software Foundation. + +"""Extractors for https://vanilla-rock.com/""" + +from .common import Extractor, Message +from .. import text + + +class VanillarockExtractor(Extractor): + """Base class for vanillarock extractors""" + category = "vanillarock" + root = "https://vanilla-rock.com" + + def __init__(self, match): + Extractor.__init__(self, match) + self.path = match.group(1) + + +class VanillarockPostExtractor(VanillarockExtractor): + """Extractor for blogposts on vanilla-rock.com""" + subcategory = "post" + directory_fmt = ("{category}", "{path}") + filename_fmt = "{num:>02}.{extension}" + archive_fmt = "{filename}" + pattern = (r"(?:https?://)?(?:www\.)?vanilla-rock\.com" + r"(/(?!category/|tag/)[^/?]+)/?$") + test = ("https://vanilla-rock.com/mizuhashi_parsee-5", { + "url": "7fb9a4d18d9fa22d7295fee8d94ab5a7a52265dd", + "keyword": "b91df99b714e1958d9636748b1c81a07c3ef52c9", + }) + + def items(self): + extr = text.extract_from(self.request(self.root + self.path).text) + name = extr("