aboutsummaryrefslogtreecommitdiffstats
path: root/yt_dlp/options.py
diff options
context:
space:
mode:
authorpukkandan <pukkandan.ytdlp@gmail.com>2022-08-24 05:42:16 +0530
committerpukkandan <pukkandan.ytdlp@gmail.com>2022-08-24 07:47:51 +0530
commitfe7866d0ed6bfa3904ce12b049a3424fdc0ea1fa (patch)
treece07f269160c2cf3c971ee83e82f19feceffcfeb /yt_dlp/options.py
parent5314b521925498356e78652fe59866116d56e1d1 (diff)
downloadhypervideo-pre-fe7866d0ed6bfa3904ce12b049a3424fdc0ea1fa.tar.lz
hypervideo-pre-fe7866d0ed6bfa3904ce12b049a3424fdc0ea1fa.tar.xz
hypervideo-pre-fe7866d0ed6bfa3904ce12b049a3424fdc0ea1fa.zip
Add option `--use-extractors`
Deprecates `--force-generic-extractor` Closes #3234, Closes #2044 Related: #4307, #1791
Diffstat (limited to 'yt_dlp/options.py')
-rw-r--r--yt_dlp/options.py12
1 files changed, 11 insertions, 1 deletions
diff --git a/yt_dlp/options.py b/yt_dlp/options.py
index 0cddb7fd5..bee531d1b 100644
--- a/yt_dlp/options.py
+++ b/yt_dlp/options.py
@@ -354,9 +354,19 @@ def create_parser():
action='store_true', dest='list_extractor_descriptions', default=False,
help='Output descriptions of all supported extractors and exit')
general.add_option(
+ '--use-extractors', '--ies',
+ action='callback', dest='allowed_extractors', metavar='NAMES', type='str',
+ default=[], callback=_list_from_options_callback,
+ help=(
+ 'Extractor names to use separated by commas. '
+ 'You can also use regexes, "all", "default" and "end" (end URL matching); '
+ 'e.g. --ies "holodex.*,end,youtube". '
+ 'Prefix the name with a "-" to exclude it, e.g. --ies default,-generic. '
+ 'Use --list-extractors for a list of available extractor names'))
+ general.add_option(
'--force-generic-extractor',
action='store_true', dest='force_generic_extractor', default=False,
- help='Force extraction to use the generic extractor')
+ help=optparse.SUPPRESS_HELP)
general.add_option(
'--default-search',
dest='default_search', metavar='PREFIX',