Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
microsoft
GitHub Repository: microsoft/vscode
Path: blob/main/src/vs/workbench/services/configurationResolver/electron-browser/configurationResolverService.ts
3296 views
1
/*---------------------------------------------------------------------------------------------
2
* Copyright (c) Microsoft Corporation. All rights reserved.
3
* Licensed under the MIT License. See License.txt in the project root for license information.
4
*--------------------------------------------------------------------------------------------*/
5
6
import { INativeWorkbenchEnvironmentService } from '../../environment/electron-browser/environmentService.js';
7
import { IConfigurationService } from '../../../../platform/configuration/common/configuration.js';
8
import { ICommandService } from '../../../../platform/commands/common/commands.js';
9
import { IWorkspaceContextService } from '../../../../platform/workspace/common/workspace.js';
10
import { IEditorService } from '../../editor/common/editorService.js';
11
import { IQuickInputService } from '../../../../platform/quickinput/common/quickInput.js';
12
import { IConfigurationResolverService } from '../common/configurationResolver.js';
13
import { InstantiationType, registerSingleton } from '../../../../platform/instantiation/common/extensions.js';
14
import { BaseConfigurationResolverService } from '../browser/baseConfigurationResolverService.js';
15
import { ILabelService } from '../../../../platform/label/common/label.js';
16
import { IShellEnvironmentService } from '../../environment/electron-browser/shellEnvironmentService.js';
17
import { IPathService } from '../../path/common/pathService.js';
18
import { IExtensionService } from '../../extensions/common/extensions.js';
19
import { IStorageService } from '../../../../platform/storage/common/storage.js';
20
21
export class ConfigurationResolverService extends BaseConfigurationResolverService {
22
23
constructor(
24
@IEditorService editorService: IEditorService,
25
@INativeWorkbenchEnvironmentService environmentService: INativeWorkbenchEnvironmentService,
26
@IConfigurationService configurationService: IConfigurationService,
27
@ICommandService commandService: ICommandService,
28
@IWorkspaceContextService workspaceContextService: IWorkspaceContextService,
29
@IQuickInputService quickInputService: IQuickInputService,
30
@ILabelService labelService: ILabelService,
31
@IShellEnvironmentService shellEnvironmentService: IShellEnvironmentService,
32
@IPathService pathService: IPathService,
33
@IExtensionService extensionService: IExtensionService,
34
@IStorageService storageService: IStorageService,
35
) {
36
super({
37
getAppRoot: (): string | undefined => {
38
return environmentService.appRoot;
39
},
40
getExecPath: (): string | undefined => {
41
return environmentService.execPath;
42
},
43
}, shellEnvironmentService.getShellEnv(), editorService, configurationService, commandService,
44
workspaceContextService, quickInputService, labelService, pathService, extensionService, storageService);
45
}
46
}
47
48
registerSingleton(IConfigurationResolverService, ConfigurationResolverService, InstantiationType.Delayed);
49
50