fix(server): render non-ASCII filenames in git output

Fixes #436
This commit is contained in:
Samatar
2026-05-19 01:16:33 +00:00
committed by GitHub
parent 9bc6210823
commit 5a1c7f266c
2 changed files with 8 additions and 2 deletions
+3 -1
View File
@@ -77,7 +77,9 @@ export function runGitCommand(
logger.trace(traceContext, "Spawning git command");
}
const child = spawnProcess("git", args, {
// `core.quotepath=false` makes git emit raw UTF-8 paths instead of
// octal-escaping non-ASCII bytes (e.g. `测试文件.txt` vs `"\346\265\213..."`).
const child = spawnProcess("git", ["-c", "core.quotepath=false", ...args], {
cwd: options.cwd,
envOverlay,
shell: false,