mirror of
https://github.com/mikf/gallery-dl.git
synced 2024-11-25 04:02:32 +01:00
[skeb] add option to download 'article' images (#1031)
This commit is contained in:
parent
43ec315a7f
commit
8cf5981ded
@ -2142,6 +2142,16 @@ Description
|
||||
Download videos.
|
||||
|
||||
|
||||
extractor.skeb.article
|
||||
----------------------
|
||||
Type
|
||||
``bool``
|
||||
Default
|
||||
``false``
|
||||
Description
|
||||
Download article images.
|
||||
|
||||
|
||||
extractor.skeb.sent-requests
|
||||
----------------------------
|
||||
Type
|
||||
|
@ -253,6 +253,12 @@
|
||||
"username": null,
|
||||
"password": null
|
||||
},
|
||||
"skeb":
|
||||
{
|
||||
"article": false,
|
||||
"sent-requests": false,
|
||||
"thumbnails": false
|
||||
},
|
||||
"smugmug":
|
||||
{
|
||||
"videos": true
|
||||
|
@ -23,6 +23,7 @@ class SkebExtractor(Extractor):
|
||||
Extractor.__init__(self, match)
|
||||
self.user_name = match.group(1)
|
||||
self.thumbnails = self.config("thumbnails", False)
|
||||
self.article = self.config("article", False)
|
||||
|
||||
def items(self):
|
||||
for user_name, post_num in self.posts():
|
||||
@ -105,6 +106,12 @@ class SkebExtractor(Extractor):
|
||||
post["file_url"] = resp["og_image_url"]
|
||||
yield post
|
||||
|
||||
if self.article and "article_image_url" in resp:
|
||||
post["content_category"] = "article"
|
||||
post["file_id"] = "article"
|
||||
post["file_url"] = resp["article_image_url"]
|
||||
yield post
|
||||
|
||||
for preview in resp["previews"]:
|
||||
post["content_category"] = "preview"
|
||||
post["file_id"] = preview["id"]
|
||||
|
Loading…
Reference in New Issue
Block a user