diff --git a/docs/supportedsites.md b/docs/supportedsites.md index 810f013b..5814fc84 100644 --- a/docs/supportedsites.md +++ b/docs/supportedsites.md @@ -1505,6 +1505,18 @@ Consider all listed sites to potentially be NSFW. Articles + + Bulbapedia + https://bulbapedia.bulbagarden.net/ + Articles + + + + PidgiWiki + https://www.pidgi.net/ + Articles + + Moebooru and MyImouto diff --git a/gallery_dl/extractor/wikimedia.py b/gallery_dl/extractor/wikimedia.py index 7f4b763d..c93f33fe 100644 --- a/gallery_dl/extractor/wikimedia.py +++ b/gallery_dl/extractor/wikimedia.py @@ -152,6 +152,16 @@ BASE_PATTERN = WikimediaExtractor.update({ "root": "https://www.mariowiki.com", "pattern": r"(?:www\.)?mariowiki\.com", }, + "bulbapedia": { + "root": "https://bulbapedia.bulbagarden.net", + "pattern": r"(?:bulbapedia|archives)\.bulbagarden\.net", + "api-path": "/w/api.php", + }, + "pidgiwiki": { + "root": "https://www.pidgi.net", + "pattern": r"(?:www\.)?pidgi\.net", + "api-path": "/wiki/api.php", + }, }) diff --git a/scripts/supportedsites.py b/scripts/supportedsites.py index 1d55291c..e12b65c2 100755 --- a/scripts/supportedsites.py +++ b/scripts/supportedsites.py @@ -101,6 +101,7 @@ CATEGORY_MAP = { "nsfwalbum" : "NSFWalbum.com", "paheal" : "rule #34", "photovogue" : "PhotoVogue", + "pidgiwiki" : "PidgiWiki", "pixeldrain" : "pixeldrain", "pornimagesxxx" : "Porn Image", "pornpics" : "PornPics.com", diff --git a/test/results/bulbapedia.py b/test/results/bulbapedia.py new file mode 100644 index 00000000..0cd7756b --- /dev/null +++ b/test/results/bulbapedia.py @@ -0,0 +1,28 @@ +# -*- coding: utf-8 -*- + +# 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. + +from gallery_dl.extractor import wikimedia + + +__tests__ = ( +{ + "#url" : "https://bulbapedia.bulbagarden.net/wiki/Jet", + "#category": ("wikimedia", "bulbapedia", "article"), + "#class" : wikimedia.WikimediaArticleExtractor, + "#pattern" : r"http://archives\.bulbagarden\.net/media/upload/\w+/\w+/[^/?#]+", + "#count" : range(10, 30), +}, + +{ + "#url" : "https://archives.bulbagarden.net/wiki/File:0460Abomasnow-Mega.png", + "#category": ("wikimedia", "bulbapedia", "file"), + "#class" : wikimedia.WikimediaArticleExtractor, + "#pattern" : r"http://archives\.bulbagarden\.net/media/upload/\w+/\w+/[^/?#]+", + "#count" : range(8, 12), + "#archive" : False, +}, + +) diff --git a/test/results/pidgiwiki.py b/test/results/pidgiwiki.py new file mode 100644 index 00000000..fc837d4c --- /dev/null +++ b/test/results/pidgiwiki.py @@ -0,0 +1,24 @@ +# -*- coding: utf-8 -*- + +# 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. + +from gallery_dl.extractor import wikimedia + + +__tests__ = ( +{ + "#url" : "https://www.pidgi.net/wiki/File:Key_art_-_Fight_Knight.png", + "#category": ("wikimedia", "pidgiwiki", "file"), + "#class" : wikimedia.WikimediaArticleExtractor, + "#urls" : "https://cdn.pidgi.net/images/0/0c/Key_art_-_Fight_Knight.png", +}, + +{ + "#url" : "https://pidgi.net/wiki/File:Key_art_-_Fight_Knight.png", + "#category": ("wikimedia", "pidgiwiki", "file"), + "#class" : wikimedia.WikimediaArticleExtractor, +}, + +)