]> jfr.im git - yt-dlp.git/commitdiff
Add `--no-quiet`
authorpukkandan <redacted>
Mon, 24 Apr 2023 13:22:09 +0000 (18:52 +0530)
committerpukkandan <redacted>
Mon, 24 Apr 2023 13:25:43 +0000 (18:55 +0530)
Closes #6796

README.md
yt_dlp/__init__.py
yt_dlp/options.py

index efb490ab1b42114670c260455051ad65d79551ce..ef0c236b5fe89aea4435ee9883cf9d034c0e06d4 100644 (file)
--- a/README.md
+++ b/README.md
@@ -752,6 +752,7 @@ ## Internet Shortcut Options:
 ## Verbosity and Simulation Options:
     -q, --quiet                     Activate quiet mode. If used with --verbose,
                                     print the log to stderr
+    --no-quiet                      Deactivate quiet mode. (Default)
     --no-warnings                   Ignore warnings
     -s, --simulate                  Do not download the video and do not write
                                     anything to disk
index bdac1212c69aafef264e0abe7a142008dda10554..79b9a7679f870fe22199efff68d2b9ef2c77c349 100644 (file)
@@ -704,7 +704,8 @@ def parse_options(argv=None):
         'dumpjson', 'dump_single_json', 'getdescription', 'getduration', 'getfilename',
         'getformat', 'getid', 'getthumbnail', 'gettitle', 'geturl'
     ))
-    opts.quiet = opts.quiet or any_getting or opts.print_json or bool(opts.forceprint)
+    if opts.quiet is None:
+        opts.quiet = any_getting or opts.print_json or bool(opts.forceprint)
 
     playlist_pps = [pp for pp in postprocessors if pp.get('when') == 'playlist']
     write_playlist_infojson = (opts.writeinfojson and not opts.clean_infojson
index d334a9caaa97b208821ba4d96d8d7a5b4d4141cf..a2f508552da575a14805e14508c6f780610d1292 100644 (file)
@@ -1079,8 +1079,12 @@ def _alias_callback(option, opt_str, value, parser, opts, nargs):
     verbosity = optparse.OptionGroup(parser, 'Verbosity and Simulation Options')
     verbosity.add_option(
         '-q', '--quiet',
-        action='store_true', dest='quiet', default=False,
+        action='store_true', dest='quiet', default=None,
         help='Activate quiet mode. If used with --verbose, print the log to stderr')
+    verbosity.add_option(
+        '--no-quiet',
+        action='store_false', dest='quiet',
+        help='Deactivate quiet mode. (Default)')
     verbosity.add_option(
         '--no-warnings',
         dest='no_warnings', action='store_true', default=False,