Skip to content

Commit e969273

Browse files
linzhengtianKBVsent
authored andcommitted
fix: reading skills on Windows (AstrBotDevs#6490)
There is an issue with reading the skill directory on the Windows system, which results in a high probability of files under the skill directory being unrecognizable, now fix it.
1 parent 6793e58 commit e969273

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

astrbot/core/skills/skill_manager.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -136,7 +136,7 @@ def _build_skill_read_command_example(path: str) -> str:
136136
return f"cat {path}"
137137
if _is_windows_prompt_path(path):
138138
command = "type"
139-
path_arg = f'"{path}"'
139+
path_arg = f'"{os.path.normpath(path)}"'
140140
else:
141141
command = "cat"
142142
path_arg = shlex.quote(path)

0 commit comments

Comments
 (0)