mirror of
https://github.com/mikf/gallery-dl.git
synced 2024-11-22 02:32:33 +01:00
[misskey] update
- rename to 'MisskeyFavoriteExtractor' - add 'access-token' option to docs - add test URLs for other instances - simplify 'pattern'
This commit is contained in:
parent
f9b7a033e0
commit
c76f0f3a1b
@ -2059,8 +2059,16 @@ Description
|
||||
Also emit metadata for text-only posts without media content.
|
||||
|
||||
|
||||
extractor.[misskey].access-token
|
||||
--------------------------------
|
||||
Type
|
||||
``string``
|
||||
Description
|
||||
Your access token, necessary to fetch favorited notes.
|
||||
|
||||
|
||||
extractor.[misskey].renotes
|
||||
----------------------------
|
||||
---------------------------
|
||||
Type
|
||||
``bool``
|
||||
Default
|
||||
@ -2070,7 +2078,7 @@ Description
|
||||
|
||||
|
||||
extractor.[misskey].replies
|
||||
----------------------------
|
||||
---------------------------
|
||||
Type
|
||||
``bool``
|
||||
Default
|
||||
|
@ -190,6 +190,7 @@
|
||||
"password": null
|
||||
},
|
||||
"misskey": {
|
||||
"access-token": null,
|
||||
"renotes": false,
|
||||
"replies": true
|
||||
},
|
||||
|
@ -1132,19 +1132,19 @@ Consider all sites to be NSFW unless otherwise known.
|
||||
<tr>
|
||||
<td>Misskey.io</td>
|
||||
<td>https://misskey.io/</td>
|
||||
<td>Images from Notes, User Profiles</td>
|
||||
<td>Favorites, Images from Notes, User Profiles</td>
|
||||
<td></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Lesbian.energy</td>
|
||||
<td>https://lesbian.energy/</td>
|
||||
<td>Images from Notes, User Profiles</td>
|
||||
<td>Favorites, Images from Notes, User Profiles</td>
|
||||
<td></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Sushi.ski</td>
|
||||
<td>https://sushi.ski/</td>
|
||||
<td>Images from Notes, User Profiles</td>
|
||||
<td>Favorites, Images from Notes, User Profiles</td>
|
||||
<td></td>
|
||||
</tr>
|
||||
|
||||
|
@ -70,7 +70,7 @@ BASE_PATTERN = MisskeyExtractor.update({
|
||||
},
|
||||
"lesbian.energy": {
|
||||
"root": "https://lesbian.energy",
|
||||
"pattern": r"lesbian\.energy"
|
||||
"pattern": r"lesbian\.energy",
|
||||
},
|
||||
"sushi.ski": {
|
||||
"root": "https://sushi.ski",
|
||||
@ -154,13 +154,15 @@ class MisskeyNoteExtractor(MisskeyExtractor):
|
||||
return (self.api.notes_show(self.item),)
|
||||
|
||||
|
||||
class MisskeyMyFavoritesExtractor(MisskeyExtractor):
|
||||
"""Extractor for images from favorites"""
|
||||
subcategory = "favorites"
|
||||
pattern = BASE_PATTERN + r"(/my/favorites|/api/i/favorites)"
|
||||
class MisskeyFavoriteExtractor(MisskeyExtractor):
|
||||
"""Extractor for favorited notes"""
|
||||
subcategory = "favorite"
|
||||
pattern = BASE_PATTERN + r"/(?:my|api/i)/favorites"
|
||||
test = (
|
||||
("https://misskey.io/my/favorites"),
|
||||
("https://misskey.io/api/i/favorites"),
|
||||
("https://lesbian.energy/my/favorites"),
|
||||
("https://sushi.ski/my/favorites"),
|
||||
)
|
||||
|
||||
def notes(self):
|
||||
|
Loading…
Reference in New Issue
Block a user