From c63a0ac1354f157e88e46b39d291a2b048695001 Mon Sep 17 00:00:00 2001 From: WANG Xuerui Date: Mon, 9 Sep 2024 14:43:05 +0800 Subject: [PATCH] style: ruff format --- ruyi/cli/__init__.py | 1 + ruyi/log/__init__.py | 6 +++++- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/ruyi/cli/__init__.py b/ruyi/cli/__init__.py index 6b97ed9..46bd699 100644 --- a/ruyi/cli/__init__.py +++ b/ruyi/cli/__init__.py @@ -13,6 +13,7 @@ "__main__.py", ) + def is_called_as_ruyi(argv0: str) -> bool: return os.path.basename(argv0).lower() in ALLOWED_RUYI_ENTRYPOINT_NAMES diff --git a/ruyi/log/__init__.py b/ruyi/log/__init__.py index dd69b7a..812bd5d 100644 --- a/ruyi/log/__init__.py +++ b/ruyi/log/__init__.py @@ -27,7 +27,11 @@ def log_time_formatter(x: datetime.datetime) -> Text: STDOUT_CONSOLE = Console(file=sys.stdout, highlight=False, soft_wrap=True) -DEBUG_CONSOLE = Console(file=sys.stderr, log_time_format=log_time_formatter, soft_wrap=True) +DEBUG_CONSOLE = Console( + file=sys.stderr, + log_time_format=log_time_formatter, + soft_wrap=True, +) LOG_CONSOLE = Console(file=sys.stderr, highlight=False, soft_wrap=True) PORCELAIN_SINK = PorcelainOutput(sys.stderr.buffer)