From f53bf1a323b7d6d547bb2d16ccffe590fecb690d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mike=20F=C3=A4hrmann?= Date: Sun, 23 Jul 2017 15:45:17 +0200 Subject: [PATCH] [thebarchive] add thread extractor --- gallery_dl/extractor/__init__.py | 1 + gallery_dl/extractor/thebarchive.py | 21 +++++++++++++++++++++ 2 files changed, 22 insertions(+) create mode 100644 gallery_dl/extractor/thebarchive.py diff --git a/gallery_dl/extractor/__init__.py b/gallery_dl/extractor/__init__.py index 7235e765..cd5cec5f 100644 --- a/gallery_dl/extractor/__init__.py +++ b/gallery_dl/extractor/__init__.py @@ -75,6 +75,7 @@ modules = [ "senmanga", "sensescans", "spectrumnexus", + "thebarchive", "tumblr", "twitter", "worldthree", diff --git a/gallery_dl/extractor/thebarchive.py b/gallery_dl/extractor/thebarchive.py new file mode 100644 index 00000000..8d44884e --- /dev/null +++ b/gallery_dl/extractor/thebarchive.py @@ -0,0 +1,21 @@ +# -*- coding: utf-8 -*- + +# Copyright 2017 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. + +"""Extract images from https://thebarchive.com/""" + +from . import chan + + +class ThebarchiveThreadExtractor(chan.FoolfuukaThreadExtractor): + """Extractor for images from threads on thebarchive.com""" + category = "thebarchive" + root = "https://thebarchive.com" + pattern = [r"(?:https?://)?thebarchive\.com/([^/]+)/thread/(\d+)"] + test = [("https://thebarchive.com/b/thread/739772332/", { + "url": "e8b18001307d130d67db31740ce57c8561b5d80c", + })]