Skip to content

Commit

Permalink
Fix for issue espressif#1092
Browse files Browse the repository at this point in the history
  • Loading branch information
dyarkovoy committed Dec 10, 2023
1 parent f549ded commit af834af
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 7 deletions.
2 changes: 1 addition & 1 deletion src/idfToolsManager.ts
Original file line number Diff line number Diff line change
Expand Up @@ -205,7 +205,7 @@ export class IdfToolsManager {
logToChannel: boolean = true
) {
const pathNameInEnv: string =
process.platform === "win32" ? "Path" : "PATH";
Object.keys(process.env).find(k=>k.toUpperCase()=="PATH");
let modifiedPath = process.env[pathNameInEnv];
if (
process.env[pathNameInEnv] &&
Expand Down
8 changes: 2 additions & 6 deletions src/utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -978,12 +978,8 @@ export function appendIdfAndToolsToPath(curWorkspace: vscode.Uri) {
"partition_table"
)}`;

let pathNameInEnv: string;
if (process.platform === "win32") {
pathNameInEnv = "Path";
} else {
pathNameInEnv = "PATH";
}
let pathNameInEnv: string =
Object.keys(process.env).find(k=>k.toUpperCase()=="PATH");
if (pathToGitDir) {
modifiedEnv[pathNameInEnv] =
pathToGitDir + path.delimiter + modifiedEnv[pathNameInEnv];
Expand Down

0 comments on commit af834af

Please sign in to comment.