mirror of
https://github.com/django/django.git
synced 2025-10-26 15:16:09 +00:00
Fixed #23107 -- Made runserver output respect --no-color.
This commit is contained in:
@@ -380,6 +380,7 @@ class BaseCommand(object):
|
||||
if options.get('no_color'):
|
||||
self.style = no_style()
|
||||
self.stderr = OutputWrapper(options.get('stderr', sys.stderr))
|
||||
os.environ["DJANGO_COLORS"] = "nocolor"
|
||||
else:
|
||||
self.stderr = OutputWrapper(options.get('stderr', sys.stderr), self.style.ERROR)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user