MCPcopy Index your code
hub / github.com/microsoft/vscode-cpptools / hasMsvcEnvironment

Function hasMsvcEnvironment

Extension/src/common.ts:1547–1572  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

1545];
1546
1547export function hasMsvcEnvironment(): boolean {
1548 const msvcEnvVars: string[] = [
1549 'DevEnvDir',
1550 'Framework40Version',
1551 'FrameworkDir',
1552 'FrameworkVersion',
1553 'INCLUDE',
1554 'LIB',
1555 'LIBPATH',
1556 'UniversalCRTSdkDir',
1557 'VCIDEInstallDir',
1558 'VCINSTALLDIR',
1559 'VCToolsRedistDir',
1560 'VisualStudioVersion',
1561 'VSINSTALLDIR',
1562 'WindowsLibPath',
1563 'WindowsSdkBinPath',
1564 'WindowsSdkDir',
1565 'WindowsSDKLibVersion',
1566 'WindowsSDKVersion'
1567 ];
1568 return msvcEnvVars.every(envVarName =>
1569 (process.env[envVarName] !== undefined && process.env[envVarName] !== '') ||
1570 extensionContext?.environmentVariableCollection?.get(envVarName) !== undefined
1571 );
1572}
1573
1574export function getMissingMsvcEnvironmentVariables(): string[] {
1575 const msvcEnvVars: string[] = [

Callers

nothing calls this directly

Calls 1

getMethod · 0.45

Tested by

no test coverage detected