mirror of
https://github.com/Microsoft/vscode
synced 2024-09-13 21:55:38 +00:00
Temporarily finalize getScopedEnvironmentVariableCollection
This commit is contained in:
parent
3a4c2b151a
commit
88799ca215
|
@ -523,8 +523,7 @@ export abstract class AbstractExtHostExtensionService extends Disposable impleme
|
|||
return that.extensionRuntime;
|
||||
},
|
||||
get environmentVariableCollection() {
|
||||
// TODO: Remove `as` cast once workspace collection proposal is finalized.
|
||||
return (that._extHostTerminalService.getEnvironmentVariableCollection(extensionDescription) as vscode.EnvironmentVariableCollection);
|
||||
return that._extHostTerminalService.getEnvironmentVariableCollection(extensionDescription);
|
||||
},
|
||||
get messagePassingProtocol() {
|
||||
if (!messagePassingProtocol) {
|
||||
|
|
|
@ -52,7 +52,7 @@ export interface IExtHostTerminalService extends ExtHostTerminalServiceShape, ID
|
|||
registerTerminalQuickFixProvider(id: string, extensionId: string, provider: vscode.TerminalQuickFixProvider): vscode.Disposable;
|
||||
getEnvironmentVariableCollection(extension: IExtensionDescription): IDefaultEnvironmentVariableCollection;
|
||||
}
|
||||
type IDefaultEnvironmentVariableCollection = vscode.EnvironmentVariableCollection | { getScopedEnvironmentVariableCollection(scope: vscode.EnvironmentVariableScope | undefined): vscode.EnvironmentVariableCollection };
|
||||
type IDefaultEnvironmentVariableCollection = vscode.EnvironmentVariableCollection & { getScopedEnvironmentVariableCollection(scope: vscode.EnvironmentVariableScope | undefined): vscode.EnvironmentVariableCollection };
|
||||
export interface ITerminalInternalOptions {
|
||||
isFeatureTerminal?: boolean;
|
||||
useShellEnvironment?: boolean;
|
||||
|
|
2
src/vscode-dts/vscode.d.ts
vendored
2
src/vscode-dts/vscode.d.ts
vendored
|
@ -7163,7 +7163,7 @@ declare module 'vscode' {
|
|||
* Gets the extension's environment variable collection for this workspace, enabling changes
|
||||
* to be applied to terminal environment variables.
|
||||
*/
|
||||
readonly environmentVariableCollection: EnvironmentVariableCollection;
|
||||
readonly environmentVariableCollection: EnvironmentVariableCollection & { getScopedEnvironmentVariableCollection(scope: EnvironmentVariableScope): EnvironmentVariableCollection };
|
||||
|
||||
/**
|
||||
* Get the absolute path of a resource contained in the extension.
|
||||
|
|
|
@ -7,15 +7,15 @@ declare module 'vscode' {
|
|||
|
||||
// https://github.com/microsoft/vscode/issues/182069
|
||||
|
||||
// export interface ExtensionContext {
|
||||
// /**
|
||||
// * Gets the extension's environment variable collection for this workspace, enabling changes
|
||||
// * to be applied to terminal environment variables.
|
||||
// *
|
||||
// * @param scope The scope to which the environment variable collection applies to.
|
||||
// */
|
||||
// readonly environmentVariableCollection: EnvironmentVariableCollection | { getScopedEnvironmentVariableCollection(scope: EnvironmentVariableScope): EnvironmentVariableCollection };
|
||||
// }
|
||||
export interface ExtensionContext {
|
||||
/**
|
||||
* Gets the extension's environment variable collection for this workspace, enabling changes
|
||||
* to be applied to terminal environment variables.
|
||||
*
|
||||
* @param scope The scope to which the environment variable collection applies to.
|
||||
*/
|
||||
readonly environmentVariableCollection: EnvironmentVariableCollection & { getScopedEnvironmentVariableCollection(scope: EnvironmentVariableScope): EnvironmentVariableCollection };
|
||||
}
|
||||
|
||||
export type EnvironmentVariableScope = {
|
||||
/**
|
||||
|
|
Loading…
Reference in a new issue