Skip to content

Commit c530489

Browse files
committed
chore(cli): ruff rewrite
1 parent 0e962e9 commit c530489

File tree

2 files changed

+4
-2
lines changed

2 files changed

+4
-2
lines changed

astrbot/cli/commands/cmd_conf.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,9 @@
22
import click
33
import hashlib
44
import zoneinfo
5-
from typing import Any, Callable
5+
from typing import Any
6+
7+
from collections.abc import Callable
68
from ..utils import get_astrbot_root, check_astrbot_root
79

810

astrbot/cli/commands/cmd_plug.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,7 @@ def new(name: str):
8686
f.write(f"# {name}\n\n{desc}\n\n# 支持\n\n[帮助文档](https://astrbot.app)\n")
8787

8888
# 重写 main.py
89-
with open(plug_path / "main.py", "r", encoding="utf-8") as f:
89+
with open(plug_path / "main.py", encoding="utf-8") as f:
9090
content = f.read()
9191

9292
new_content = content.replace(

0 commit comments

Comments
 (0)