Skip to content

Commit 26d69c9

Browse files
authored
fix: reading skills on Windows (#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 3dcdb8b commit 26d69c9

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

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)