Fix WSL UNC setup runner casing (#4139)

This commit is contained in:
Neil
2026-05-31 05:47:21 -07:00
committed by GitHub
parent 236b6fd23e
commit 0fd484c75d
2 changed files with 15 additions and 2 deletions
+2 -2
View File
@@ -20,12 +20,12 @@ export function buildSetupRunnerCommand(
function isWslUncPath(path: string): boolean {
const normalized = path.replace(/\\/g, '/')
return /^\/\/(wsl\.localhost|wsl\$)\//.test(normalized)
return /^\/\/(wsl\.localhost|wsl\$)\//i.test(normalized)
}
function wslUncToLinuxPath(windowsPath: string): string {
const normalized = windowsPath.replace(/\\/g, '/')
const match = normalized.match(/^\/\/(wsl\.localhost|wsl\$)\/[^/]+(\/.*)?$/)
const match = normalized.match(/^\/\/(wsl\.localhost|wsl\$)\/[^/]+(\/.*)?$/i)
return match?.[2] || '/'
}