general.add_option(
'-i', '--ignore-errors',
action='store_true', dest='ignoreerrors',
- help='Ignore download and postprocessing errors. The download will be considered successfull even if the postprocessing fails')
+ help='Ignore download and postprocessing errors. The download will be considered successful even if the postprocessing fails')
general.add_option(
'--no-abort-on-error',
action='store_const', dest='ignoreerrors', const='only_download',
general.add_option(
'--mark-watched',
action='store_true', dest='mark_watched', default=False,
- help='Mark videos watched (YouTube only)')
+ help='Mark videos watched (even with --simulate). Currently only supported for YouTube')
general.add_option(
'--no-mark-watched',
action='store_false', dest='mark_watched',
'--date',
metavar='DATE', dest='date', default=None,
help=(
- 'Download only videos uploaded in this date. '
+ 'Download only videos uploaded on this date. '
'The date can be "YYYYMMDD" or in the format '
'"(now|today)[+-][0-9](day|week|month|year)(s)?"'))
selection.add_option(
help="Don't give any special preference to free containers (default)")
video_format.add_option(
'--check-formats',
- action='store_true', dest='check_formats', default=None,
- help='Check that the formats selected are actually downloadable')
+ action='store_const', const='selected', dest='check_formats', default=None,
+ help='Check that the selected formats are actually downloadable')
+ video_format.add_option(
+ '--check-all-formats',
+ action='store_true', dest='check_formats',
+ help='Check all formats for whether they are actually downloadable')
video_format.add_option(
'--no-check-formats',
action='store_false', dest='check_formats',
- help='Do not check that the formats selected are actually downloadable')
+ help='Do not check that the formats are actually downloadable')
video_format.add_option(
'-F', '--list-formats',
action='store_true', dest='listformats',
dest='encoding', metavar='ENCODING',
help='Force the specified encoding (experimental)')
workarounds.add_option(
- '--no-check-certificate',
+ '--no-check-certificates',
action='store_true', dest='no_check_certificate', default=False,
help='Suppress HTTPS certificate validation')
workarounds.add_option(
'--ignore-no-formats-error',
action='store_true', dest='ignore_no_formats_error', default=False,
help=(
- 'Ignore "No video formats" error. Usefull for extracting metadata '
+ 'Ignore "No video formats" error. Useful for extracting metadata '
'even if the videos are not actually available for download (experimental)'))
verbosity.add_option(
'--no-ignore-no-formats-error',
help='Output progress bar as new lines')
verbosity.add_option(
'--no-progress',
- action='store_true', dest='noprogress', default=False,
+ action='store_true', dest='noprogress', default=None,
help='Do not print progress bar')
+ verbosity.add_option(
+ '--progress',
+ action='store_false', dest='noprogress',
+ help='Show progress bar, even if in quiet mode')
verbosity.add_option(
'--console-title',
action='store_true', dest='consoletitle', default=False,
help='Display progress in console titlebar')
+ verbosity.add_option(
+ '--progress-template',
+ metavar='[TYPES:]TEMPLATE', dest='progress_template', default={}, type='str',
+ action='callback', callback=_dict_from_options_callback,
+ callback_kwargs={
+ 'allowed_keys': '(download|postprocess)(-title)?',
+ 'default_key': 'download'
+ }, help=(
+ 'Template for progress outputs, optionally prefixed with one of "download:" (default), '
+ '"download-title:" (the console title), "postprocess:", or "postprocess-title:". '
+ 'The video\'s fields are accessible under the "info" key and '
+ 'the progress attributes are accessible under "progress" key. E.g.: '
+ # TODO: Document the fields inside "progress"
+ '--console-title --progress-template "download-title:%(info.id)s-%(progress.eta)s"'))
verbosity.add_option(
'-v', '--verbose',
action='store_true', dest='verbose', default=False,
dest='batchfile', metavar='FILE',
help="File containing URLs to download ('-' for stdin), one URL per line. "
"Lines starting with '#', ';' or ']' are considered as comments and ignored")
+ filesystem.add_option(
+ '--no-batch-file',
+ dest='batchfile', action='store_const', const=None,
+ help='Do not read URLs from batch file (default)')
filesystem.add_option(
'--id', default=False,
action='store_true', dest='useid', help=optparse.SUPPRESS_HELP)
filesystem.add_option(
'--windows-filenames',
action='store_true', dest='windowsfilenames', default=False,
- help='Force filenames to be windows compatible')
+ help='Force filenames to be Windows-compatible')
filesystem.add_option(
'--no-windows-filenames',
action='store_false', dest='windowsfilenames',
- help='Make filenames windows compatible only if using windows (default)')
+ help='Make filenames Windows-compatible only if using Windows (default)')
filesystem.add_option(
'--trim-filenames', '--trim-file-names', metavar='LENGTH',
dest='trim_file_name', default=0, type=int,
help='Limit the filename length (excluding extension) to the specified number of characters')
- filesystem.add_option(
- '--auto-number',
- action='store_true', dest='autonumber', default=False,
- help=optparse.SUPPRESS_HELP)
- filesystem.add_option(
- '--title',
- action='store_true', dest='usetitle', default=False,
- help=optparse.SUPPRESS_HELP)
- filesystem.add_option(
- '--literal', default=False,
- action='store_true', dest='usetitle',
- help=optparse.SUPPRESS_HELP)
filesystem.add_option(
'-w', '--no-overwrites',
action='store_false', dest='overwrites', default=None,
postproc.add_option(
'--remove-chapters',
metavar='REGEX', dest='remove_chapters', action='append',
- help='Remove chapters whose title matches the given regular expression. This option can be used multiple times')
+ help=(
+ 'Remove chapters whose title matches the given regular expression. '
+ 'Time ranges prefixed by a "*" can also be used in place of chapters to remove the specified range. '
+ 'Eg: --remove-chapters "*10:15-15:00" --remove-chapters "intro". '
+ 'This option can be used multiple times'))
postproc.add_option(
'--no-remove-chapters', dest='remove_chapters', action='store_const', const=None,
help='Do not remove any chapters from the file (default)')
parser.error('config-location %s does not exist.' % location)
config = _readOptions(location, default=None)
if config:
- configs['custom'], paths['config'] = config, location
+ configs['custom'], paths['custom'] = config, location
if opts.ignoreconfig:
return
argv = configs['system'] + configs['user'] + configs['home'] + configs['portable'] + configs['custom'] + configs['command-line']
opts, args = parser.parse_args(argv)
if opts.verbose:
- for label in ('System', 'User', 'Portable', 'Home', 'Custom', 'Command-line'):
+ for label in ('Command-line', 'Custom', 'Portable', 'Home', 'User', 'System'):
key = label.lower()
if paths.get(key):
write_string(f'[debug] {label} config file: {paths[key]}\n')