mirror of
https://github.com/soimort/you-get.git
synced 2025-02-11 20:52:31 +03:00
Merge branch 'develop' of https://github.com/soimort/you-get into pandatv-fix-#1612
This commit is contained in:
commit
503421da1d
@ -127,10 +127,11 @@ def bilibili_download(url, output_dir='.', merge=True, info_only=False, **kwargs
|
||||
|
||||
if re.match(r'https?://bangumi\.bilibili\.com/', url):
|
||||
# quick hack for bangumi URLs
|
||||
episode_id = r1(r'first_ep_id = "(\d+)"', html)
|
||||
episode_id = r1(r'#(\d+)$', url) or r1(r'first_ep_id = "(\d+)"', html)
|
||||
cont = post_content('http://bangumi.bilibili.com/web_api/get_source',
|
||||
post_data={'episode_id': episode_id})
|
||||
cid = json.loads(cont)['result']['cid']
|
||||
title = '%s [%s]' % (title, episode_id)
|
||||
bilibili_download_by_cid(str(cid), title, output_dir=output_dir, merge=merge, info_only=info_only)
|
||||
|
||||
else:
|
||||
|
@ -17,6 +17,8 @@ def nanagogo_download(url, output_dir='.', merge=True, info_only=False, **kwargs
|
||||
info = json.loads(get_content(api_url))
|
||||
|
||||
items = []
|
||||
if info['data']['posts']['post'] is None:
|
||||
return
|
||||
for i in info['data']['posts']['post']['body']:
|
||||
if 'image' in i:
|
||||
image_url = i['image']
|
||||
|
@ -1,4 +1,4 @@
|
||||
#!/usr/bin/env python
|
||||
|
||||
script_name = 'you-get'
|
||||
__version__ = '0.4.595'
|
||||
__version__ = '0.4.626'
|
||||
|
@ -24,6 +24,7 @@
|
||||
"Programming Language :: Python :: 3.3",
|
||||
"Programming Language :: Python :: 3.4",
|
||||
"Programming Language :: Python :: 3.5",
|
||||
"Programming Language :: Python :: 3.6",
|
||||
"Topic :: Internet",
|
||||
"Topic :: Internet :: WWW/HTTP",
|
||||
"Topic :: Multimedia",
|
||||
|
Loading…
Reference in New Issue
Block a user