fix(opencode): normalize tool paths across platforms (#2459)

Normalize backslash paths for OpenCode formatting and add branch coverage for GitHub coordination behavior.
This commit is contained in:
Alexis D.
2026-07-26 03:13:49 -07:00
committed by GitHub
parent 5a4777777d
commit 71438391e8
5 changed files with 805 additions and 1 deletions
+1 -1
View File
@@ -107,7 +107,7 @@ function buildFormatterCommand(formatter: Formatter, filePath: string, cwd?: str
// Normalize to forward slashes so the emitted command is identical on every
// platform. `path.normalize` yields backslashes on Windows, which broke the
// command string (and Windows CI); all formatter CLIs accept `/` on Windows.
const normalizedPath = path.normalize(filePath).split(path.sep).join("/")
const normalizedPath = path.normalize(filePath).replace(/\\/g, "/")
// Build command based on formatter and platform
const commands: Record<Formatter, string> = {