video_format.add_option(
'-f', '--format',
action='store', dest='format', metavar='FORMAT', default=None,
- help='Video format code, see the "FORMAT SELECTION" for all the info')
+ help='Video format code, see "FORMAT SELECTION" for more details')
+ video_format.add_option(
+ '-S', '--format-sort',
+ dest='format_sort', default=[],
+ action='callback', callback=_comma_separated_values_options_callback, type='str',
+ help='Sort the formats by the fields given, see "Sorting Formats" for more details')
+ video_format.add_option(
+ '--format-sort-force', '--S-force',
+ action='store_true', dest='format_sort_force', metavar='FORMAT', default=False,
+ help=(
+ 'Force user specified sort order to have precedence over all fields, '
+ 'see "Sorting Formats" for more details'))
+ video_format.add_option(
+ '--no-format-sort-force',
+ action='store_false', dest='format_sort_force', metavar='FORMAT', default=False,
+ help=(
+ 'Some fields have precedence over the user specified sort order (default), '
+ 'see "Sorting Formats" for more details'))
+ video_format.add_option(
+ '--video-multistreams',
+ action='store_true', dest='allow_multiple_video_streams', default=True,
+ help='Allow multiple video streams to be merged into a single file (default)')
+ video_format.add_option(
+ '--no-video-multistreams',
+ action='store_false', dest='allow_multiple_video_streams',
+ help='Only one video stream is downloaded for each output file')
+ video_format.add_option(
+ '--audio-multistreams',
+ action='store_true', dest='allow_multiple_audio_streams', default=True,
+ help='Allow multiple audio streams to be merged into a single file (default)')
+ video_format.add_option(
+ '--no-audio-multistreams',
+ action='store_false', dest='allow_multiple_audio_streams',
+ help='Only one audio stream is downloaded for each output file')
video_format.add_option(
'--all-formats',
action='store_const', dest='format', const='all',
action='store_true', dest='list_thumbnails', default=False,
help='Simulate and list all available thumbnail formats')
- postproc = optparse.OptionGroup(parser, 'Post-processing Options')
+ link = optparse.OptionGroup(parser, 'Internet Shortcut Options')
+ link.add_option(
+ '--write-link',
+ action='store_true', dest='writelink', default=False,
+ help='Write an internet shortcut file, depending on the current platform (.url/.webloc/.desktop). The URL may be cached by the OS.')
+ link.add_option(
+ '--write-url-link',
+ action='store_true', dest='writeurllink', default=False,
+ help='Write a Windows internet shortcut file (.url). Note that the OS caches the URL based on the file path.')
+ link.add_option(
+ '--write-webloc-link',
+ action='store_true', dest='writewebloclink', default=False,
+ help='Write a macOS internet shortcut file (.webloc)')
+ link.add_option(
+ '--write-desktop-link',
+ action='store_true', dest='writedesktoplink', default=False,
+ help='Write a Linux internet shortcut file (.desktop)')
+
+ postproc = optparse.OptionGroup(parser, 'Post-Processing Options')
postproc.add_option(
'-x', '--extract-audio',
action='store_true', dest='extractaudio', default=False,
parser.add_option_group(downloader)
parser.add_option_group(filesystem)
parser.add_option_group(thumbnail)
+ parser.add_option_group(link)
parser.add_option_group(verbosity)
parser.add_option_group(workarounds)
parser.add_option_group(video_format)