mirror of
https://github.com/soimort/you-get.git
synced 2025-02-09 03:37:52 +03:00
enable choozing first to download by using "--first"
This commit is contained in:
parent
1c841f7e8c
commit
7aa7ebedcd
@ -615,7 +615,12 @@ class Bilibili(VideoExtractor):
|
|||||||
|
|
||||||
if pn == len(initial_state['videoData']['pages']):
|
if pn == len(initial_state['videoData']['pages']):
|
||||||
# non-interative video
|
# non-interative video
|
||||||
for pi in range(1, pn + 1):
|
# enable choozing first to download by using "--first"
|
||||||
|
p_first = 1
|
||||||
|
args = kwargs.get('args')
|
||||||
|
if ('first' in args and args.first!= None):
|
||||||
|
p_first = int(args.first)
|
||||||
|
for pi in range(p_first, pn + 1):
|
||||||
purl = 'https://www.bilibili.com/video/av%s?p=%s' % (aid, pi)
|
purl = 'https://www.bilibili.com/video/av%s?p=%s' % (aid, pi)
|
||||||
self.__class__().download_by_url(purl, **kwargs)
|
self.__class__().download_by_url(purl, **kwargs)
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user