Skip to content

Commit 21c7a36

Browse files
committed
suggestion
1 parent 45c9fdf commit 21c7a36

File tree

1 file changed

+3
-10
lines changed

1 file changed

+3
-10
lines changed

Doc/library/argparse.rst

Lines changed: 3 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -638,16 +638,9 @@ by setting ``color`` to ``False``::
638638
... help='an integer for the accumulator')
639639
>>> parser.parse_args(['--help'])
640640

641-
Note that the environment variables take precedence over ``color=True``, but
642-
``color=False`` takes precedence over the environment variables. For
643-
instance, if the environment variable ``NO_COLOR`` is set then there will be
644-
no colored output even if the ``color`` parameter is explicitly set to
645-
``True``. If the environment variable ``FORCE_COLOR`` is set then colored
646-
output will be depending on the ``color`` parameter. If both are set then
647-
``NO_COLOR`` takes precedence.
648-
649-
See :ref:`controlling color <using-on-controlling-color>` for more information
650-
on controlling colored output globally.
641+
When ``color=True``, colored output depends on both the environment variables
642+
and the terminal capabilities. But when ``color=False``, colored output is
643+
always disabled.
651644

652645
.. versionadded:: 3.14
653646

0 commit comments

Comments
 (0)