Skip to content

Commit 570abef

Browse files
committed
Linting and updated docs.
1 parent 637b118 commit 570abef

File tree

3 files changed

+12
-4
lines changed

3 files changed

+12
-4
lines changed

README.rst

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -152,3 +152,9 @@ To install with ``conda``:
152152
$ conda install consolekit
153153
154154
.. end installation
155+
156+
Additionally, for better support, install `psutil <https://pypi.org/project/psutil/>`_ by specifying the ``terminals`` extra:
157+
158+
.. code-block:: bash
159+
160+
$ python -m pip install consolekit[terminals]

consolekit/terminal_colours.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -125,9 +125,7 @@
125125

126126
def resolve_color_default(color: ColourTrilean = None) -> ColourTrilean:
127127
"""
128-
Internal helper to get the default value of the color flag. If a
129-
value is passed it's returned unchanged, otherwise it's looked up from
130-
the current context.
128+
Helper to get the default value of the color flag.
131129
132130
If a value is passed it is returned unchanged,
133131
otherwise it's looked up from the current context.

consolekit/utils.py

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,18 +27,22 @@
2727
#
2828

2929
# stdlib
30+
import contextlib
3031
import difflib
3132
import os
3233
import sys
3334
from functools import lru_cache
3435
from itertools import cycle
3536
from types import ModuleType
36-
from typing import IO, List, Sequence
37+
from typing import IO, Callable, ContextManager, List, Sequence
3738

3839
# 3rd party
3940
import click
4041
from domdf_python_tools.import_tools import discover, discover_entry_points
4142
from domdf_python_tools.stringlist import StringList
43+
from domdf_python_tools.words import SANS_SERIF_ITALIC_LETTERS
44+
from mistletoe import block_token, span_token # type: ignore
45+
from mistletoe.base_renderer import BaseRenderer # type: ignore
4246

4347
# this package
4448
from consolekit.terminal_colours import Colour, Cursor, Fore, Style, code_to_chars

0 commit comments

Comments
 (0)