fix(git bash): fixes char encoding on windows git bash

closes #275
This commit is contained in:
Christopher Pickering 2022-07-07 13:38:23 -05:00
parent 0f9dd6478b
commit 3ef7c16e8d
No known key found for this signature in database
GPG key ID: E14DB3B0A0FACF84

View file

@ -9,6 +9,15 @@ from colorama import Fore, Style
from .settings import Config
try:
# this is used for windows + gitbash to set encoding correctly.
import sys
sys.stdout.reconfigure(encoding="utf-8") # type: ignore[attr-defined]
# pylint:disable=W0703
except BaseException:
pass
def print_output(
config: Config, file_errors: List[Dict[Any, Any]], file_count: int