Skip to content

Commit 0cedb62

Browse files
committed
fix: quote the path in addEnv on Unix
1 parent 79079b9 commit 0cedb62

File tree

5 files changed

+7
-7
lines changed

5 files changed

+7
-7
lines changed

dist/setup_cpp.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/setup_cpp.js.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/setup_cpp.mjs

Lines changed: 1 addition & 1 deletion
Large diffs are not rendered by default.

dist/setup_cpp.mjs.map

Lines changed: 1 addition & 1 deletion
Large diffs are not rendered by default.

src/utils/env/addEnv.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -79,14 +79,14 @@ async function addPathSystem(path: string) {
7979
await execPowershell(
8080
`$USER_PATH=([Environment]::GetEnvironmentVariable("PATH", "User")); [Environment]::SetEnvironmentVariable("PATH", "${path};$USER_PATH", "User")`
8181
)
82-
info(`${path} was added to the PATH.`)
82+
info(`"${path}" was added to the PATH.`)
8383
return
8484
}
8585
case "linux":
8686
case "darwin": {
8787
setupCppInProfile()
88-
appendFileSync(cpprc_path, `\nexport PATH=${path}:$PATH\n`)
89-
info(`${path} was added to "${cpprc_path}"`)
88+
appendFileSync(cpprc_path, `\nexport PATH="${path}:$PATH"\n`)
89+
info(`"${path}" was added to "${cpprc_path}"`)
9090
return
9191
}
9292
default: {

0 commit comments

Comments
 (0)