Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions apps/desktop/src/main/env-utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ import { execFileSync, execFile } from 'child_process';
import { promisify } from 'util';
import { getSentryEnvForSubprocess } from './sentry';
import { isWindows, isUnix, getPathDelimiter, getNpmCommand } from './platform';
import { normalizeEnvPathKey } from './agent/env-utils';

const execFileAsync = promisify(execFile);

Expand Down Expand Up @@ -236,6 +237,9 @@ export function getAugmentedEnv(additionalPaths?: string[]): Record<string, stri
const env = { ...process.env } as Record<string, string>;
const pathSeparator = getPathDelimiter();

// Normalize PATH key to handle case differences on Windows.
normalizeEnvPathKey(env);

// Get all candidate paths (platform + additional)
const candidatePaths = getExpandedPlatformPaths(additionalPaths);

Expand Down Expand Up @@ -411,6 +415,9 @@ export async function getAugmentedEnvAsync(additionalPaths?: string[]): Promise<
const env = { ...process.env } as Record<string, string>;
const pathSeparator = getPathDelimiter();

// Normalize PATH key to handle case differences on Windows.
normalizeEnvPathKey(env);

// Get all candidate paths (platform + additional)
const candidatePaths = getExpandedPlatformPaths(additionalPaths);

Expand Down
Loading