mirror of
https://github.com/soimort/you-get.git
synced 2025-02-03 08:43:58 +03:00
[bilibili] quick hack for bangumi URLs again (fix #1362)
This commit is contained in:
parent
315634332a
commit
a3f3d880f9
@ -33,6 +33,11 @@ def bilibili_download(url, output_dir='.', merge=True, info_only=False, **kwargs
|
|||||||
bilibili_download_by_api(url, output_dir=output_dir, merge=merge, info_only=info_only, **kwargs)
|
bilibili_download_by_api(url, output_dir=output_dir, merge=merge, info_only=info_only, **kwargs)
|
||||||
return
|
return
|
||||||
|
|
||||||
|
if re.match(r'https?://bangumi\.bilibili\.com/', url):
|
||||||
|
# quick hack for bangumi URLs
|
||||||
|
html = get_content(url)
|
||||||
|
url = r1(r'"([^"]+)" class="v-av-link"', html)
|
||||||
|
|
||||||
html = get_content(url)
|
html = get_content(url)
|
||||||
main_title = r1_of([r'<meta name="title" content="\s*([^<>]{1,999})\s*" />',
|
main_title = r1_of([r'<meta name="title" content="\s*([^<>]{1,999})\s*" />',
|
||||||
r'<h1[^>]*>\s*([^<>]+)\s*</h1>'], html)
|
r'<h1[^>]*>\s*([^<>]+)\s*</h1>'], html)
|
||||||
|
Loading…
Reference in New Issue
Block a user