1
0
mirror of https://github.com/yt-dlp/yt-dlp.git synced 2025-11-01 07:05:14 +00:00

[core] Support auto-tty and no_color-tty for --color (#10453)

Authored by: Grub4K
This commit is contained in:
Simon Sawicki
2024-07-16 21:51:56 +02:00
committed by GitHub
parent 66ce3d76d8
commit d9cbced493
3 changed files with 10 additions and 5 deletions

View File

@@ -468,7 +468,7 @@ def validate_options(opts):
default_downloader = ed.get_basename()
for policy in opts.color.values():
if policy not in ('always', 'auto', 'no_color', 'never'):
if policy not in ('always', 'auto', 'auto-tty', 'no_color', 'no_color-tty', 'never'):
raise ValueError(f'"{policy}" is not a valid color policy')
warnings, deprecation_warnings = [], []