parent
27667093b4
commit
4f930b907f
|
@ -176,7 +176,7 @@ export class TerminalConfigHelper implements IBrowserTerminalConfigHelper {
|
|||
const platformKey = osOverride === platform.OperatingSystem.Windows ? 'windows' : osOverride === platform.OperatingSystem.Macintosh ? 'osx' : 'linux';
|
||||
const shellConfigValue = this._workspaceConfigurationService.inspect<string>(`terminal.integrated.shell.${platformKey}`);
|
||||
const shellArgsConfigValue = this._workspaceConfigurationService.inspect<string[]>(`terminal.integrated.shellArgs.${platformKey}`);
|
||||
const envConfigValue = this._workspaceConfigurationService.inspect<string[]>(`terminal.integrated.env.${platformKey}`);
|
||||
const envConfigValue = this._workspaceConfigurationService.inspect<{ [key: string]: string }>(`terminal.integrated.env.${platformKey}`);
|
||||
|
||||
// Check if workspace setting exists and whether it's whitelisted
|
||||
let isWorkspaceShellAllowed: boolean | undefined = false;
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
|
||||
import * as nls from 'vs/nls';
|
||||
|
||||
import { registerColor, ColorIdentifier } from 'vs/platform/theme/common/colorRegistry';
|
||||
import { registerColor, ColorIdentifier, ColorDefaults } from 'vs/platform/theme/common/colorRegistry';
|
||||
import { PANEL_BORDER, PANEL_BACKGROUND } from 'vs/workbench/common/theme';
|
||||
|
||||
/**
|
||||
|
@ -37,7 +37,7 @@ export const TERMINAL_BORDER_COLOR = registerColor('terminal.border', {
|
|||
hc: PANEL_BORDER
|
||||
}, nls.localize('terminal.border', 'The color of the border that separates split panes within the terminal. This defaults to panel.border.'));
|
||||
|
||||
export const ansiColorMap = {
|
||||
export const ansiColorMap: { [key: string]: { index: number, defaults: ColorDefaults } } = {
|
||||
'terminal.ansiBlack': {
|
||||
index: 0,
|
||||
defaults: {
|
||||
|
|
|
@ -92,7 +92,7 @@ function _getLangEnvVariable(locale?: string) {
|
|||
if (n === 1) {
|
||||
// app.getLocale can return just a language without a variant, fill in the variant for
|
||||
// supported languages as many shells expect a 2-part locale.
|
||||
const languageVariants = {
|
||||
const languageVariants: { [key: string]: string } = {
|
||||
cs: 'CZ',
|
||||
de: 'DE',
|
||||
en: 'US',
|
||||
|
|
|
@ -108,7 +108,7 @@ async function detectAvailableWindowsShells(): Promise<IShellDefinition[]> {
|
|||
useWSLexe = true;
|
||||
}
|
||||
|
||||
const expectedLocations = {
|
||||
const expectedLocations: { [key: string]: string[] } = {
|
||||
'Command Prompt': [`${system32Path}\\cmd.exe`],
|
||||
PowerShell: [`${system32Path}\\WindowsPowerShell\\v1.0\\powershell.exe`],
|
||||
'PowerShell Core': [await getShellPathFromRegistry('pwsh')],
|
||||
|
|
|
@ -37,7 +37,7 @@ export async function getMainProcessParentEnv(): Promise<IProcessEnvironment> {
|
|||
});
|
||||
} while (name === codeProcessName);
|
||||
const rawEnv = await readFile(`/proc/${pid}/environ`, 'utf8');
|
||||
const env = {};
|
||||
const env: IProcessEnvironment = {};
|
||||
rawEnv.split('\0').forEach(e => {
|
||||
const i = e.indexOf('=');
|
||||
env[e.substr(0, i)] = e.substr(i + 1);
|
||||
|
|
Loading…
Reference in a new issue