Skip to content

Commit bf7c689

Browse files
always add Swift path to terminal PATH (#950)
1 parent 8456249 commit bf7c689

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

src/terminal.ts

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -55,8 +55,7 @@ export class SwiftEnvironmentVariablesManager implements vscode.Disposable {
5555
return;
5656
}
5757

58-
const pathEnv = process.env["PATH"] ?? "";
59-
if (!pathEnv.includes(configuration.path)) {
58+
if (configuration.path) {
6059
environment.prepend("PATH", configuration.path + pathSeparator);
6160
}
6261
for (const variable in configuration.swiftEnvironmentVariables) {
@@ -75,7 +74,7 @@ export class SwiftTerminalProfileProvider implements vscode.TerminalProfileProvi
7574
...configuration.swiftEnvironmentVariables,
7675
};
7776
const pathEnv = process.env["PATH"] ?? "";
78-
if (!pathEnv.includes(configuration.path)) {
77+
if (configuration.path) {
7978
env["PATH"] = configuration.path + pathSeparator + pathEnv;
8079
}
8180
return new vscode.TerminalProfile({

0 commit comments

Comments
 (0)