chore(vscode): update to 1.55.2

This commit is contained in:
Akash Satheesan
2021-04-09 11:32:27 +05:30
1102 changed files with 39988 additions and 23544 deletions

View File

@ -6,6 +6,42 @@
//@ts-check
'use strict';
// Setup current working directory in all our node & electron processes
// - Windows: call `process.chdir()` to always set application folder as cwd
// - Posix: allow to change the current working dir via `VSCODE_CWD` if defined
// - all OS: store the `process.cwd()` inside `VSCODE_CWD` for consistent lookups
// TODO@bpasero revisit if chdir() on Windows is needed in the future still
function setupCurrentWorkingDirectory() {
const path = require('path');
try {
let cwd = process.env['VSCODE_CWD'];
// remember current working directory in environment
// unless it was given to us already from outside
if (typeof cwd !== 'string') {
cwd = process.cwd();
process.env['VSCODE_CWD'] = cwd;
}
// Windows: always set application folder as current working dir
if (process.platform === 'win32') {
process.chdir(path.dirname(process.execPath));
}
// Linux/macOS: allow to change current working dir based on env
else {
if (cwd !== process.cwd()) {
process.chdir(cwd);
}
}
} catch (err) {
console.error(err);
}
}
setupCurrentWorkingDirectory();
/**
* Add support for redirecting the loading of node modules
*