mirror of
https://github.com/nathom/streamrip.git
synced 2025-05-15 15:44:58 -04:00
Add option to specify number of search results
Signed-off-by: nathom <nathanthomas707@gmail.com>
This commit is contained in:
parent
4abe96825f
commit
05235b7080
1 changed files with 4 additions and 1 deletions
|
@ -196,6 +196,7 @@ def search(ctx, **kwargs):
|
||||||
@click.option(
|
@click.option(
|
||||||
"-s", "--scrape", is_flag=True, help="Download all of the items in a list."
|
"-s", "--scrape", is_flag=True, help="Download all of the items in a list."
|
||||||
)
|
)
|
||||||
|
@click.option("-n", "--num-items", default=50, help="Number of items to parse.")
|
||||||
@click.pass_context
|
@click.pass_context
|
||||||
def discover(ctx, **kwargs):
|
def discover(ctx, **kwargs):
|
||||||
"""Search for albums in Qobuz's featured lists.
|
"""Search for albums in Qobuz's featured lists.
|
||||||
|
@ -244,7 +245,9 @@ def discover(ctx, **kwargs):
|
||||||
core.download()
|
core.download()
|
||||||
return
|
return
|
||||||
|
|
||||||
if core.interactive_search(kwargs["list"], "qobuz", "featured"):
|
if core.interactive_search(
|
||||||
|
kwargs["list"], "qobuz", "featured", limit=int(kwargs["num_items"])
|
||||||
|
):
|
||||||
core.download()
|
core.download()
|
||||||
else:
|
else:
|
||||||
none_chosen()
|
none_chosen()
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue