@codingame/monaco-vscode-extensions-service-override 21.6.0 → 22.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +29 -30
- package/vscode/src/vs/platform/extensionManagement/common/extensionManagementCLI.js +28 -28
- package/vscode/src/vs/workbench/api/browser/mainThreadAuthentication.d.ts +3 -3
- package/vscode/src/vs/workbench/api/browser/mainThreadAuthentication.js +41 -32
- package/vscode/src/vs/workbench/api/browser/mainThreadCLICommands.js +1 -1
- package/vscode/src/vs/workbench/api/browser/mainThreadChatAgents2.js +6 -5
- package/vscode/src/vs/workbench/api/browser/mainThreadChatSessions.d.ts +5 -2
- package/vscode/src/vs/workbench/api/browser/mainThreadChatSessions.js +44 -4
- package/vscode/src/vs/workbench/api/browser/mainThreadComments.js +2 -2
- package/vscode/src/vs/workbench/api/browser/mainThreadCustomEditors.js +3 -3
- package/vscode/src/vs/workbench/api/browser/mainThreadDocumentsAndEditors.js +1 -1
- package/vscode/src/vs/workbench/api/browser/mainThreadEditSessionIdentityParticipant.js +1 -1
- package/vscode/src/vs/workbench/api/browser/mainThreadEditorTabs.d.ts +1 -1
- package/vscode/src/vs/workbench/api/browser/mainThreadEditorTabs.js +2 -2
- package/vscode/src/vs/workbench/api/browser/mainThreadEditors.d.ts +1 -1
- package/vscode/src/vs/workbench/api/browser/mainThreadEditors.js +1 -1
- package/vscode/src/vs/workbench/api/browser/mainThreadExtensionService.js +11 -11
- package/vscode/src/vs/workbench/api/browser/mainThreadFileSystemEventService.js +20 -20
- package/vscode/src/vs/workbench/api/browser/mainThreadLanguageFeatures.js +39 -27
- package/vscode/src/vs/workbench/api/browser/mainThreadLanguageModelTools.js +4 -1
- package/vscode/src/vs/workbench/api/browser/mainThreadLanguageModels.js +47 -41
- package/vscode/src/vs/workbench/api/browser/mainThreadMcp.d.ts +6 -2
- package/vscode/src/vs/workbench/api/browser/mainThreadMcp.js +75 -27
- package/vscode/src/vs/workbench/api/browser/mainThreadMessageService.js +4 -4
- package/vscode/src/vs/workbench/api/browser/mainThreadNotebookDocumentsAndEditors.js +1 -1
- package/vscode/src/vs/workbench/api/browser/mainThreadNotebookEditors.js +1 -1
- package/vscode/src/vs/workbench/api/browser/mainThreadNotebookSaveParticipant.js +1 -1
- package/vscode/src/vs/workbench/api/browser/mainThreadOutputService.js +3 -3
- package/vscode/src/vs/workbench/api/browser/mainThreadProgress.js +1 -1
- package/vscode/src/vs/workbench/api/browser/mainThreadSCM.js +9 -2
- package/vscode/src/vs/workbench/api/browser/mainThreadSaveParticipant.js +1 -1
- package/vscode/src/vs/workbench/api/browser/mainThreadSearch.js +1 -1
- package/vscode/src/vs/workbench/api/browser/mainThreadTask.js +1 -1
- package/vscode/src/vs/workbench/api/browser/mainThreadTerminalService.js +21 -7
- package/vscode/src/vs/workbench/api/browser/mainThreadTunnelService.d.ts +1 -0
- package/vscode/src/vs/workbench/api/browser/mainThreadTunnelService.js +5 -2
- package/vscode/src/vs/workbench/api/browser/mainThreadUriOpeners.js +2 -2
- package/vscode/src/vs/workbench/api/browser/mainThreadWebviewPanels.js +1 -1
- package/vscode/src/vs/workbench/api/browser/mainThreadWebviews.js +1 -1
- package/vscode/src/vs/workbench/api/browser/mainThreadWorkspace.js +5 -5
- package/vscode/src/vs/workbench/contrib/customEditor/common/customTextEditorModel.js +1 -1
- package/vscode/src/vs/workbench/contrib/externalUriOpener/common/contributedOpeners.js +1 -1
- package/vscode/src/vs/workbench/services/extensionManagement/browser/extensionBisect.js +23 -23
- package/vscode/src/vs/workbench/services/extensionManagement/browser/webExtensionsScannerService.js +2 -2
- package/vscode/src/vs/workbench/services/extensions/common/abstractExtensionService.js +12 -12
- package/vscode/src/vs/workbench/services/extensions/common/extensionHostManager.js +1 -1
- package/vscode/src/vs/workbench/services/extensions/common/extensionsProposedApi.js +1 -1
- package/vscode/src/vs/workbench/services/extensions/common/extensionsUtil.js +4 -4
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@codingame/monaco-vscode-extensions-service-override",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "22.0.0",
|
|
4
4
|
"private": false,
|
|
5
5
|
"description": "VSCode public API plugged on the monaco editor - extensions service-override",
|
|
6
6
|
"keywords": [],
|
|
@@ -15,35 +15,34 @@
|
|
|
15
15
|
},
|
|
16
16
|
"type": "module",
|
|
17
17
|
"dependencies": {
|
|
18
|
-
"@codingame/monaco-vscode-05a2a821-e4de-5941-b7f9-bbf01c09f229-common": "
|
|
19
|
-
"@codingame/monaco-vscode-
|
|
20
|
-
"@codingame/monaco-vscode-
|
|
21
|
-
"@codingame/monaco-vscode-
|
|
22
|
-
"@codingame/monaco-vscode-
|
|
23
|
-
"@codingame/monaco-vscode-
|
|
24
|
-
"@codingame/monaco-vscode-
|
|
25
|
-
"@codingame/monaco-vscode-
|
|
26
|
-
"@codingame/monaco-vscode-
|
|
27
|
-
"@codingame/monaco-vscode-
|
|
28
|
-
"@codingame/monaco-vscode-
|
|
29
|
-
"@codingame/monaco-vscode-
|
|
30
|
-
"@codingame/monaco-vscode-
|
|
31
|
-
"@codingame/monaco-vscode-
|
|
32
|
-
"@codingame/monaco-vscode-
|
|
33
|
-
"@codingame/monaco-vscode-
|
|
34
|
-
"@codingame/monaco-vscode-
|
|
35
|
-
"@codingame/monaco-vscode-
|
|
36
|
-
"@codingame/monaco-vscode-a9da9abe-278d-5ce6-9418-99c7c07c5c37-common": "
|
|
37
|
-
"@codingame/monaco-vscode-api": "
|
|
38
|
-
"@codingame/monaco-vscode-b994942c-360d-5b68-8a33-77d4bde6b714-common": "
|
|
39
|
-
"@codingame/monaco-vscode-bba55be6-41a2-50cd-a3cc-8bafa35bfa89-common": "
|
|
40
|
-
"@codingame/monaco-vscode-bf94ddb5-e436-506a-9763-5ab86b642508-common": "
|
|
41
|
-
"@codingame/monaco-vscode-caeb744c-8e3f-5c11-80fb-0f057d24d544-common": "
|
|
42
|
-
"@codingame/monaco-vscode-
|
|
43
|
-
"@codingame/monaco-vscode-
|
|
44
|
-
"@codingame/monaco-vscode-
|
|
45
|
-
"@codingame/monaco-vscode-
|
|
46
|
-
"@codingame/monaco-vscode-files-service-override": "21.6.0"
|
|
18
|
+
"@codingame/monaco-vscode-05a2a821-e4de-5941-b7f9-bbf01c09f229-common": "22.0.0",
|
|
19
|
+
"@codingame/monaco-vscode-249dc928-1da3-51c1-82d0-45e0ba9d08a1-common": "22.0.0",
|
|
20
|
+
"@codingame/monaco-vscode-256d5b78-0649-50e9-8354-2807f95f68f4-common": "22.0.0",
|
|
21
|
+
"@codingame/monaco-vscode-2a94c04a-b85b-5669-b06b-89c1bfa11cb9-common": "22.0.0",
|
|
22
|
+
"@codingame/monaco-vscode-4a3ac544-9a61-534c-88df-756262793ef7-common": "22.0.0",
|
|
23
|
+
"@codingame/monaco-vscode-4bf376c2-03c7-58cb-8303-c67aeefa3d3d-common": "22.0.0",
|
|
24
|
+
"@codingame/monaco-vscode-5084de40-f866-5cb5-9d9b-33a10f6f235d-common": "22.0.0",
|
|
25
|
+
"@codingame/monaco-vscode-571c8352-7953-5038-9f09-e03bb6219a0e-common": "22.0.0",
|
|
26
|
+
"@codingame/monaco-vscode-60014c9d-b815-501d-83a9-4b08725c2ec2-common": "22.0.0",
|
|
27
|
+
"@codingame/monaco-vscode-622c0cca-d5fa-59b6-b730-0715afcf93ee-common": "22.0.0",
|
|
28
|
+
"@codingame/monaco-vscode-670aae94-7f88-54d7-90ea-6fcbef423557-common": "22.0.0",
|
|
29
|
+
"@codingame/monaco-vscode-6845754f-e617-5ed9-8aaa-6ca3653a9532-common": "22.0.0",
|
|
30
|
+
"@codingame/monaco-vscode-7969284a-1a12-5148-9750-fcf9656a693f-common": "22.0.0",
|
|
31
|
+
"@codingame/monaco-vscode-7f39b6f1-3542-5430-8760-0f404d7a7cee-common": "22.0.0",
|
|
32
|
+
"@codingame/monaco-vscode-8ccb7637-50ea-5359-97bf-00015d7fe567-common": "22.0.0",
|
|
33
|
+
"@codingame/monaco-vscode-a17e9d37-b6c1-5556-8402-5db73960fae3-common": "22.0.0",
|
|
34
|
+
"@codingame/monaco-vscode-a654b07e-8806-5425-b124-18f03ba8e11a-common": "22.0.0",
|
|
35
|
+
"@codingame/monaco-vscode-a8d3bd74-e63e-5327-96e8-4f931661e329-common": "22.0.0",
|
|
36
|
+
"@codingame/monaco-vscode-a9da9abe-278d-5ce6-9418-99c7c07c5c37-common": "22.0.0",
|
|
37
|
+
"@codingame/monaco-vscode-api": "22.0.0",
|
|
38
|
+
"@codingame/monaco-vscode-b994942c-360d-5b68-8a33-77d4bde6b714-common": "22.0.0",
|
|
39
|
+
"@codingame/monaco-vscode-bba55be6-41a2-50cd-a3cc-8bafa35bfa89-common": "22.0.0",
|
|
40
|
+
"@codingame/monaco-vscode-bf94ddb5-e436-506a-9763-5ab86b642508-common": "22.0.0",
|
|
41
|
+
"@codingame/monaco-vscode-caeb744c-8e3f-5c11-80fb-0f057d24d544-common": "22.0.0",
|
|
42
|
+
"@codingame/monaco-vscode-eb7d5efd-2e60-59f8-9ba4-9a8ae8cb2957-common": "22.0.0",
|
|
43
|
+
"@codingame/monaco-vscode-eba0b9b3-174c-5dae-9867-a37810ca1808-common": "22.0.0",
|
|
44
|
+
"@codingame/monaco-vscode-f22e7e55-aee8-5b52-a6bc-950efd9f5890-common": "22.0.0",
|
|
45
|
+
"@codingame/monaco-vscode-files-service-override": "22.0.0"
|
|
47
46
|
},
|
|
48
47
|
"main": "index.js",
|
|
49
48
|
"module": "index.js",
|
|
@@ -12,9 +12,9 @@ import { IExtensionManagementService, IExtensionGalleryService } from '@codingam
|
|
|
12
12
|
import { getIdAndVersion, areSameExtensions, getGalleryExtensionId, getExtensionId } from '@codingame/monaco-vscode-api/vscode/vs/platform/extensionManagement/common/extensionManagementUtil';
|
|
13
13
|
import { ExtensionType, EXTENSION_CATEGORIES } from '@codingame/monaco-vscode-api/vscode/vs/platform/extensions/common/extensions';
|
|
14
14
|
|
|
15
|
-
const notFound = (id) => ( localize(
|
|
15
|
+
const notFound = (id) => ( localize(1822, "Extension '{0}' not found.", id));
|
|
16
16
|
const useId = ( localize(
|
|
17
|
-
|
|
17
|
+
1823,
|
|
18
18
|
"Make sure you use the full extension ID, including the publisher, e.g.: {0}",
|
|
19
19
|
'ms-dotnettools.csharp'
|
|
20
20
|
));
|
|
@@ -51,7 +51,7 @@ let ExtensionManagementCLI = class ExtensionManagementCLI {
|
|
|
51
51
|
return;
|
|
52
52
|
}
|
|
53
53
|
if (this.location) {
|
|
54
|
-
this.logger.info(( localize(
|
|
54
|
+
this.logger.info(( localize(1824, "Extensions installed on {0}:", this.location)));
|
|
55
55
|
}
|
|
56
56
|
extensions = extensions.sort((e1, e2) => e1.identifier.id.localeCompare(e2.identifier.id));
|
|
57
57
|
let lastId = undefined;
|
|
@@ -66,7 +66,7 @@ let ExtensionManagementCLI = class ExtensionManagementCLI {
|
|
|
66
66
|
const failed = [];
|
|
67
67
|
try {
|
|
68
68
|
if (extensions.length) {
|
|
69
|
-
this.logger.info(this.location ? ( localize(
|
|
69
|
+
this.logger.info(this.location ? ( localize(1825, "Installing extensions on {0}...", this.location)) : ( localize(1826, "Installing extensions...")));
|
|
70
70
|
}
|
|
71
71
|
const installVSIXInfos = [];
|
|
72
72
|
const installExtensionInfos = [];
|
|
@@ -109,11 +109,11 @@ let ExtensionManagementCLI = class ExtensionManagementCLI {
|
|
|
109
109
|
}
|
|
110
110
|
}
|
|
111
111
|
catch (error) {
|
|
112
|
-
this.logger.error(( localize(
|
|
112
|
+
this.logger.error(( localize(1827, "Error while installing extensions: {0}", getErrorMessage(error))));
|
|
113
113
|
throw error;
|
|
114
114
|
}
|
|
115
115
|
if (failed.length) {
|
|
116
|
-
throw ( new Error(( localize(
|
|
116
|
+
throw ( new Error(( localize(1828, "Failed Installing Extensions: {0}", failed.join(', ')))));
|
|
117
117
|
}
|
|
118
118
|
}
|
|
119
119
|
async updateExtensions(profileLocation) {
|
|
@@ -125,7 +125,7 @@ let ExtensionManagementCLI = class ExtensionManagementCLI {
|
|
|
125
125
|
}
|
|
126
126
|
}
|
|
127
127
|
this.logger.trace(( localize(
|
|
128
|
-
|
|
128
|
+
1829,
|
|
129
129
|
"Fetching latest versions for {0} extensions",
|
|
130
130
|
installedExtensionsQuery.length
|
|
131
131
|
)));
|
|
@@ -142,11 +142,11 @@ let ExtensionManagementCLI = class ExtensionManagementCLI {
|
|
|
142
142
|
}
|
|
143
143
|
}
|
|
144
144
|
if (!extensionsToUpdate.length) {
|
|
145
|
-
this.logger.info(( localize(
|
|
145
|
+
this.logger.info(( localize(1830, "No extension to update")));
|
|
146
146
|
return;
|
|
147
147
|
}
|
|
148
148
|
this.logger.info(( localize(
|
|
149
|
-
|
|
149
|
+
1831,
|
|
150
150
|
"Updating extensions: {0}",
|
|
151
151
|
( extensionsToUpdate.map(ext => ext.extension.identifier.id)).join(', ')
|
|
152
152
|
)));
|
|
@@ -154,7 +154,7 @@ let ExtensionManagementCLI = class ExtensionManagementCLI {
|
|
|
154
154
|
for (const extensionResult of installationResult) {
|
|
155
155
|
if (extensionResult.error) {
|
|
156
156
|
this.logger.error(( localize(
|
|
157
|
-
|
|
157
|
+
1832,
|
|
158
158
|
"Error while updating extension {0}: {1}",
|
|
159
159
|
extensionResult.identifier.id,
|
|
160
160
|
getErrorMessage(extensionResult.error)
|
|
@@ -162,7 +162,7 @@ let ExtensionManagementCLI = class ExtensionManagementCLI {
|
|
|
162
162
|
}
|
|
163
163
|
else {
|
|
164
164
|
this.logger.info(( localize(
|
|
165
|
-
|
|
165
|
+
1833,
|
|
166
166
|
"Extension '{0}' v{1} was successfully updated.",
|
|
167
167
|
extensionResult.identifier.id,
|
|
168
168
|
extensionResult.local?.manifest.version
|
|
@@ -177,7 +177,7 @@ let ExtensionManagementCLI = class ExtensionManagementCLI {
|
|
|
177
177
|
if (installedExtension) {
|
|
178
178
|
if (!force && (!version || (version === 'prerelease' && installedExtension.preRelease))) {
|
|
179
179
|
this.logger.info(( localize(
|
|
180
|
-
|
|
180
|
+
1834,
|
|
181
181
|
"Extension '{0}' v{1} is already installed. Use '--force' option to update to latest version or provide '@<version>' to install a specific version, for example: '{2}@1.2.3'.",
|
|
182
182
|
id,
|
|
183
183
|
installedExtension.manifest.version,
|
|
@@ -186,7 +186,7 @@ let ExtensionManagementCLI = class ExtensionManagementCLI {
|
|
|
186
186
|
return false;
|
|
187
187
|
}
|
|
188
188
|
if (version && installedExtension.manifest.version === version) {
|
|
189
|
-
this.logger.info(( localize(
|
|
189
|
+
this.logger.info(( localize(1835, "Extension '{0}' is already installed.", `${id}@${version}`)));
|
|
190
190
|
return false;
|
|
191
191
|
}
|
|
192
192
|
if (installedExtension.preRelease && version !== 'prerelease') {
|
|
@@ -223,24 +223,24 @@ let ExtensionManagementCLI = class ExtensionManagementCLI {
|
|
|
223
223
|
if (installedExtension) {
|
|
224
224
|
if (gallery.version === installedExtension.manifest.version) {
|
|
225
225
|
this.logger.info(( localize(
|
|
226
|
-
|
|
226
|
+
1835,
|
|
227
227
|
"Extension '{0}' is already installed.",
|
|
228
228
|
version ? `${id}@${version}` : id
|
|
229
229
|
)));
|
|
230
230
|
return;
|
|
231
231
|
}
|
|
232
232
|
this.logger.info(( localize(
|
|
233
|
-
|
|
233
|
+
1836,
|
|
234
234
|
"Updating the extension '{0}' to the version {1}",
|
|
235
235
|
id,
|
|
236
236
|
gallery.version
|
|
237
237
|
)));
|
|
238
238
|
}
|
|
239
239
|
if (installOptions.isBuiltin) {
|
|
240
|
-
this.logger.info(version ? ( localize(
|
|
240
|
+
this.logger.info(version ? ( localize(1837, "Installing builtin extension '{0}' v{1}...", id, version)) : ( localize(1838, "Installing builtin extension '{0}'...", id)));
|
|
241
241
|
}
|
|
242
242
|
else {
|
|
243
|
-
this.logger.info(version ? ( localize(
|
|
243
|
+
this.logger.info(version ? ( localize(1839, "Installing extension '{0}' v{1}...", id, version)) : ( localize(1840, "Installing extension '{0}'...", id)));
|
|
244
244
|
}
|
|
245
245
|
extensionsToInstall.push({
|
|
246
246
|
extension: gallery,
|
|
@@ -252,7 +252,7 @@ let ExtensionManagementCLI = class ExtensionManagementCLI {
|
|
|
252
252
|
for (const extensionResult of installationResult) {
|
|
253
253
|
if (extensionResult.error) {
|
|
254
254
|
this.logger.error(( localize(
|
|
255
|
-
|
|
255
|
+
1841,
|
|
256
256
|
"Error while installing extension {0}: {1}",
|
|
257
257
|
extensionResult.identifier.id,
|
|
258
258
|
getErrorMessage(extensionResult.error)
|
|
@@ -261,7 +261,7 @@ let ExtensionManagementCLI = class ExtensionManagementCLI {
|
|
|
261
261
|
}
|
|
262
262
|
else {
|
|
263
263
|
this.logger.info(( localize(
|
|
264
|
-
|
|
264
|
+
1842,
|
|
265
265
|
"Extension '{0}' v{1} was successfully installed.",
|
|
266
266
|
extensionResult.identifier.id,
|
|
267
267
|
extensionResult.local?.manifest.version
|
|
@@ -280,11 +280,11 @@ let ExtensionManagementCLI = class ExtensionManagementCLI {
|
|
|
280
280
|
if (valid) {
|
|
281
281
|
try {
|
|
282
282
|
await this.extensionManagementService.install(vsix, { ...installOptions, installGivenVersion: true });
|
|
283
|
-
this.logger.info(( localize(
|
|
283
|
+
this.logger.info(( localize(1843, "Extension '{0}' was successfully installed.", basename(vsix))));
|
|
284
284
|
}
|
|
285
285
|
catch (error) {
|
|
286
286
|
if (isCancellationError(error)) {
|
|
287
|
-
this.logger.info(( localize(
|
|
287
|
+
this.logger.info(( localize(1844, "Cancelled installing extension '{0}'.", basename(vsix))));
|
|
288
288
|
}
|
|
289
289
|
else {
|
|
290
290
|
throw error;
|
|
@@ -319,7 +319,7 @@ let ExtensionManagementCLI = class ExtensionManagementCLI {
|
|
|
319
319
|
const newer = installedExtensions.find(local => areSameExtensions(extensionIdentifier, local.identifier) && semverExports.gt(local.manifest.version, manifest.version));
|
|
320
320
|
if (newer) {
|
|
321
321
|
this.logger.info(( localize(
|
|
322
|
-
|
|
322
|
+
1845,
|
|
323
323
|
"A newer version of extension '{0}' v{1} is already installed. Use '--force' option to downgrade to older version.",
|
|
324
324
|
newer.identifier.id,
|
|
325
325
|
newer.manifest.version,
|
|
@@ -347,7 +347,7 @@ let ExtensionManagementCLI = class ExtensionManagementCLI {
|
|
|
347
347
|
}
|
|
348
348
|
if (( extensionsToUninstall.some(e => e.type === ExtensionType.System))) {
|
|
349
349
|
this.logger.info(( localize(
|
|
350
|
-
|
|
350
|
+
1846,
|
|
351
351
|
"Extension '{0}' is a Built-in extension and cannot be uninstalled",
|
|
352
352
|
id
|
|
353
353
|
)));
|
|
@@ -355,26 +355,26 @@ let ExtensionManagementCLI = class ExtensionManagementCLI {
|
|
|
355
355
|
}
|
|
356
356
|
if (!force && ( extensionsToUninstall.some(e => e.isBuiltin))) {
|
|
357
357
|
this.logger.info(( localize(
|
|
358
|
-
|
|
358
|
+
1847,
|
|
359
359
|
"Extension '{0}' is marked as a Built-in extension by user. Please use '--force' option to uninstall it.",
|
|
360
360
|
id
|
|
361
361
|
)));
|
|
362
362
|
return;
|
|
363
363
|
}
|
|
364
|
-
this.logger.info(( localize(
|
|
364
|
+
this.logger.info(( localize(1848, "Uninstalling {0}...", id)));
|
|
365
365
|
for (const extensionToUninstall of extensionsToUninstall) {
|
|
366
366
|
await this.extensionManagementService.uninstall(extensionToUninstall, { profileLocation });
|
|
367
367
|
}
|
|
368
368
|
if (this.location) {
|
|
369
369
|
this.logger.info(( localize(
|
|
370
|
-
|
|
370
|
+
1849,
|
|
371
371
|
"Extension '{0}' was successfully uninstalled from {1}!",
|
|
372
372
|
id,
|
|
373
373
|
this.location
|
|
374
374
|
)));
|
|
375
375
|
}
|
|
376
376
|
else {
|
|
377
|
-
this.logger.info(( localize(
|
|
377
|
+
this.logger.info(( localize(1850, "Extension '{0}' was successfully uninstalled!", id)));
|
|
378
378
|
}
|
|
379
379
|
}
|
|
380
380
|
}
|
|
@@ -392,7 +392,7 @@ let ExtensionManagementCLI = class ExtensionManagementCLI {
|
|
|
392
392
|
});
|
|
393
393
|
}
|
|
394
394
|
notInstalled(id) {
|
|
395
|
-
return this.location ? ( localize(
|
|
395
|
+
return this.location ? ( localize(1851, "Extension '{0}' is not installed on {1}.", id, this.location)) : ( localize(1852, "Extension '{0}' is not installed.", id));
|
|
396
396
|
}
|
|
397
397
|
};
|
|
398
398
|
ExtensionManagementCLI = ( __decorate([
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { Disposable } from "@codingame/monaco-vscode-api/vscode/vs/base/common/lifecycle";
|
|
2
2
|
import { IExtHostContext } from "../../services/extensions/common/extHostCustomers.js";
|
|
3
|
-
import { AuthenticationSession, AuthenticationSessionsChangeEvent, AuthenticationSessionAccount } from "@codingame/monaco-vscode-api/vscode/vs/workbench/services/authentication/common/authentication";
|
|
3
|
+
import { AuthenticationSession, AuthenticationSessionsChangeEvent, AuthenticationSessionAccount, IAuthenticationWwwAuthenticateRequest } from "@codingame/monaco-vscode-api/vscode/vs/workbench/services/authentication/common/authentication";
|
|
4
4
|
import { IAuthenticationExtensionsService } from "@codingame/monaco-vscode-api/vscode/vs/workbench/services/authentication/common/authentication.service";
|
|
5
5
|
import { IAuthenticationService } from "@codingame/monaco-vscode-api/vscode/vs/workbench/services/authentication/common/authentication.service";
|
|
6
|
-
import {
|
|
6
|
+
import { MainThreadAuthenticationShape } from "@codingame/monaco-vscode-api/vscode/vs/workbench/api/common/extHost.protocol";
|
|
7
7
|
import { IDialogService } from "@codingame/monaco-vscode-api/vscode/vs/platform/dialogs/common/dialogs.service";
|
|
8
8
|
import { INotificationService } from "@codingame/monaco-vscode-api/vscode/vs/platform/notification/common/notification.service";
|
|
9
9
|
import { IExtensionService } from "@codingame/monaco-vscode-api/vscode/vs/workbench/services/extensions/common/extensions.service";
|
|
@@ -72,7 +72,7 @@ export declare class MainThreadAuthentication extends Disposable implements Main
|
|
|
72
72
|
private loginPrompt;
|
|
73
73
|
private continueWithIncorrectAccountPrompt;
|
|
74
74
|
private doGetSession;
|
|
75
|
-
$getSession(providerId: string, scopeListOrRequest: ReadonlyArray<string> |
|
|
75
|
+
$getSession(providerId: string, scopeListOrRequest: ReadonlyArray<string> | IAuthenticationWwwAuthenticateRequest, extensionId: string, extensionName: string, options: AuthenticationGetSessionOptions): Promise<AuthenticationSession | undefined>;
|
|
76
76
|
$getAccounts(providerId: string): Promise<ReadonlyArray<AuthenticationSessionAccount>>;
|
|
77
77
|
private _sentClientIdUsageEvents;
|
|
78
78
|
private sendClientIdUsageTelemetry;
|
|
@@ -3,7 +3,7 @@ import { __decorate, __param } from '@codingame/monaco-vscode-api/external/tslib
|
|
|
3
3
|
import { Disposable, DisposableMap } from '@codingame/monaco-vscode-api/vscode/vs/base/common/lifecycle';
|
|
4
4
|
import { localize } from '@codingame/monaco-vscode-api/vscode/vs/nls';
|
|
5
5
|
import { extHostNamedCustomer } from '../../services/extensions/common/extHostCustomers.js';
|
|
6
|
-
import {
|
|
6
|
+
import { isAuthenticationWwwAuthenticateRequest } from '@codingame/monaco-vscode-api/vscode/vs/workbench/services/authentication/common/authentication';
|
|
7
7
|
import { IAuthenticationService, IAuthenticationExtensionsService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/services/authentication/common/authentication.service';
|
|
8
8
|
import { ExtHostContext, MainContext } from '@codingame/monaco-vscode-api/vscode/vs/workbench/api/common/extHost.protocol';
|
|
9
9
|
import { IDialogService } from '@codingame/monaco-vscode-api/vscode/vs/platform/dialogs/common/dialogs.service';
|
|
@@ -178,8 +178,8 @@ let MainThreadAuthentication = class MainThreadAuthentication extends Disposable
|
|
|
178
178
|
return await deferredPromise.p;
|
|
179
179
|
}
|
|
180
180
|
$showContinueNotification(message) {
|
|
181
|
-
const yes = ( localize(
|
|
182
|
-
const no = ( localize(
|
|
181
|
+
const yes = ( localize(2429, "Yes"));
|
|
182
|
+
const no = ( localize(2430, "No"));
|
|
183
183
|
const deferredPromise = ( new DeferredPromise());
|
|
184
184
|
let result = false;
|
|
185
185
|
const handle = this.notificationService.prompt(Severity.Warning, message, [{
|
|
@@ -221,13 +221,13 @@ let MainThreadAuthentication = class MainThreadAuthentication extends Disposable
|
|
|
221
221
|
else {
|
|
222
222
|
message = recreatingSession
|
|
223
223
|
? ( localize(
|
|
224
|
-
|
|
224
|
+
2431,
|
|
225
225
|
"The extension '{0}' wants you to sign in again using {1}.",
|
|
226
226
|
extensionName,
|
|
227
227
|
provider.label
|
|
228
228
|
))
|
|
229
229
|
: ( localize(
|
|
230
|
-
|
|
230
|
+
2432,
|
|
231
231
|
"The extension '{0}' wants to sign in using {1}.",
|
|
232
232
|
extensionName,
|
|
233
233
|
provider.label
|
|
@@ -235,7 +235,7 @@ let MainThreadAuthentication = class MainThreadAuthentication extends Disposable
|
|
|
235
235
|
}
|
|
236
236
|
const buttons = [
|
|
237
237
|
{
|
|
238
|
-
label: ( localize(
|
|
238
|
+
label: ( localize(2433, "&&Allow")),
|
|
239
239
|
run() {
|
|
240
240
|
return true;
|
|
241
241
|
},
|
|
@@ -243,7 +243,7 @@ let MainThreadAuthentication = class MainThreadAuthentication extends Disposable
|
|
|
243
243
|
];
|
|
244
244
|
if (options?.learnMore) {
|
|
245
245
|
buttons.push({
|
|
246
|
-
label: ( localize(
|
|
246
|
+
label: ( localize(2434, "Learn more")),
|
|
247
247
|
run: async () => {
|
|
248
248
|
const result = this.loginPrompt(provider, extensionName, recreatingSession, options);
|
|
249
249
|
await this.openerService.open(URI.revive(options.learnMore), { allowCommands: true });
|
|
@@ -262,9 +262,9 @@ let MainThreadAuthentication = class MainThreadAuthentication extends Disposable
|
|
|
262
262
|
}
|
|
263
263
|
async continueWithIncorrectAccountPrompt(chosenAccountLabel, requestedAccountLabel) {
|
|
264
264
|
const result = await this.dialogService.prompt({
|
|
265
|
-
message: ( localize(
|
|
265
|
+
message: ( localize(2435, "Incorrect account detected")),
|
|
266
266
|
detail: ( localize(
|
|
267
|
-
|
|
267
|
+
2436,
|
|
268
268
|
"The chosen account, {0}, does not match the requested account, {1}.",
|
|
269
269
|
chosenAccountLabel,
|
|
270
270
|
requestedAccountLabel
|
|
@@ -273,11 +273,11 @@ let MainThreadAuthentication = class MainThreadAuthentication extends Disposable
|
|
|
273
273
|
cancelButton: true,
|
|
274
274
|
buttons: [
|
|
275
275
|
{
|
|
276
|
-
label: ( localize(
|
|
276
|
+
label: ( localize(2437, 'Keep {0}', chosenAccountLabel)),
|
|
277
277
|
run: () => chosenAccountLabel
|
|
278
278
|
},
|
|
279
279
|
{
|
|
280
|
-
label: ( localize(
|
|
280
|
+
label: ( localize(2438, 'Login with {0}', requestedAccountLabel)),
|
|
281
281
|
run: () => requestedAccountLabel
|
|
282
282
|
}
|
|
283
283
|
],
|
|
@@ -371,15 +371,14 @@ let MainThreadAuthentication = class MainThreadAuthentication extends Disposable
|
|
|
371
371
|
return undefined;
|
|
372
372
|
}
|
|
373
373
|
async $getSession(providerId, scopeListOrRequest, extensionId, extensionName, options) {
|
|
374
|
-
const scopes =
|
|
374
|
+
const scopes = isAuthenticationWwwAuthenticateRequest(scopeListOrRequest) ? scopeListOrRequest.fallbackScopes : scopeListOrRequest;
|
|
375
375
|
if (scopes) {
|
|
376
376
|
this.sendClientIdUsageTelemetry(extensionId, providerId, scopes);
|
|
377
377
|
}
|
|
378
378
|
const session = await this.doGetSession(providerId, scopeListOrRequest, extensionId, extensionName, options);
|
|
379
379
|
if (session) {
|
|
380
380
|
this.sendProviderUsageTelemetry(extensionId, providerId);
|
|
381
|
-
|
|
382
|
-
this.authenticationUsageService.addAccountUsage(providerId, session.account.label, scopes, extensionId, extensionName);
|
|
381
|
+
this.authenticationUsageService.addAccountUsage(providerId, session.account.label, session.scopes, extensionId, extensionName);
|
|
383
382
|
}
|
|
384
383
|
return session;
|
|
385
384
|
}
|
|
@@ -420,16 +419,16 @@ let MainThreadAuthentication = class MainThreadAuthentication extends Disposable
|
|
|
420
419
|
async $showDeviceCodeModal(userCode, verificationUri) {
|
|
421
420
|
const { result } = await this.dialogService.prompt({
|
|
422
421
|
type: Severity.Info,
|
|
423
|
-
message: ( localize(
|
|
422
|
+
message: ( localize(2439, "Device Code Authentication")),
|
|
424
423
|
detail: ( localize(
|
|
425
|
-
|
|
424
|
+
2440,
|
|
426
425
|
"Your code: {0}\n\nTo complete authentication, navigate to {1} and enter the code above.",
|
|
427
426
|
userCode,
|
|
428
427
|
verificationUri
|
|
429
428
|
)),
|
|
430
429
|
buttons: [
|
|
431
430
|
{
|
|
432
|
-
label: ( localize(
|
|
431
|
+
label: ( localize(2441, "Copy & Continue")),
|
|
433
432
|
run: () => true
|
|
434
433
|
}
|
|
435
434
|
],
|
|
@@ -441,46 +440,56 @@ let MainThreadAuthentication = class MainThreadAuthentication extends Disposable
|
|
|
441
440
|
return await this.openerService.open(( URI.parse(verificationUri)));
|
|
442
441
|
}
|
|
443
442
|
catch (error) {
|
|
444
|
-
this.notificationService.error(( localize(
|
|
443
|
+
this.notificationService.error(( localize(2442, "Failed to open {0}", verificationUri)));
|
|
445
444
|
}
|
|
446
445
|
}
|
|
447
446
|
return false;
|
|
448
447
|
}
|
|
449
448
|
async $promptForClientRegistration(authorizationServerUrl) {
|
|
449
|
+
const redirectUrls = 'http://127.0.0.1:33418\nhttps://vscode.dev/redirect';
|
|
450
450
|
const result = await this.dialogService.prompt({
|
|
451
451
|
type: Severity.Info,
|
|
452
|
-
message: ( localize(
|
|
452
|
+
message: ( localize(2443, "Dynamic Client Registration not supported")),
|
|
453
453
|
detail: ( localize(
|
|
454
|
-
|
|
455
|
-
"The authorization server '{0}' does not support automatic client registration. Do you want to proceed by manually providing a client registration (client ID)?\n\nNote: When registering your OAuth application, make sure to include these redirect URIs:\
|
|
456
|
-
authorizationServerUrl
|
|
454
|
+
2444,
|
|
455
|
+
"The authorization server '{0}' does not support automatic client registration. Do you want to proceed by manually providing a client registration (client ID)?\n\nNote: When registering your OAuth application, make sure to include these redirect URIs:\n{1}",
|
|
456
|
+
authorizationServerUrl,
|
|
457
|
+
redirectUrls
|
|
457
458
|
)),
|
|
458
459
|
buttons: [
|
|
459
460
|
{
|
|
460
|
-
label: ( localize(
|
|
461
|
-
run: () =>
|
|
462
|
-
|
|
461
|
+
label: ( localize(2445, "Copy URIs & Proceed")),
|
|
462
|
+
run: async () => {
|
|
463
|
+
try {
|
|
464
|
+
await this.clipboardService.writeText(redirectUrls);
|
|
465
|
+
}
|
|
466
|
+
catch (error) {
|
|
467
|
+
this.notificationService.error(( localize(2446, "Failed to copy redirect URIs to clipboard.")));
|
|
468
|
+
}
|
|
469
|
+
return true;
|
|
470
|
+
}
|
|
471
|
+
},
|
|
463
472
|
],
|
|
464
473
|
cancelButton: {
|
|
465
|
-
label: ( localize(
|
|
474
|
+
label: ( localize(2447, "Cancel")),
|
|
466
475
|
run: () => false
|
|
467
476
|
}
|
|
468
477
|
});
|
|
469
478
|
if (!result) {
|
|
470
479
|
return undefined;
|
|
471
480
|
}
|
|
472
|
-
const sharedTitle = ( localize(
|
|
481
|
+
const sharedTitle = ( localize(2448, "Add Client Registration Details"));
|
|
473
482
|
const clientId = await this.quickInputService.input({
|
|
474
483
|
title: sharedTitle,
|
|
475
484
|
prompt: ( localize(
|
|
476
|
-
|
|
485
|
+
2449,
|
|
477
486
|
"Enter an existing client ID that has been registered with the following redirect URIs: http://127.0.0.1:33418, https://vscode.dev/redirect"
|
|
478
487
|
)),
|
|
479
|
-
placeHolder: ( localize(
|
|
488
|
+
placeHolder: ( localize(2450, "OAuth client ID (azye39d...)")),
|
|
480
489
|
ignoreFocusLost: true,
|
|
481
490
|
validateInput: async (value) => {
|
|
482
491
|
if (!value || value.trim().length === 0) {
|
|
483
|
-
return localize(
|
|
492
|
+
return localize(2451, "Client ID is required");
|
|
484
493
|
}
|
|
485
494
|
return undefined;
|
|
486
495
|
}
|
|
@@ -491,11 +500,11 @@ let MainThreadAuthentication = class MainThreadAuthentication extends Disposable
|
|
|
491
500
|
const clientSecret = await this.quickInputService.input({
|
|
492
501
|
title: sharedTitle,
|
|
493
502
|
prompt: ( localize(
|
|
494
|
-
|
|
503
|
+
2452,
|
|
495
504
|
"(optional) Enter an existing client secret associated with the client id '{0}' or leave this field blank",
|
|
496
505
|
clientId
|
|
497
506
|
)),
|
|
498
|
-
placeHolder: ( localize(
|
|
507
|
+
placeHolder: ( localize(2453, "OAuth client secret (wer32o50f...) or leave it blank")),
|
|
499
508
|
password: true,
|
|
500
509
|
ignoreFocusLost: true
|
|
501
510
|
});
|
|
@@ -92,7 +92,7 @@ let RemoteExtensionManagementCLI = class RemoteExtensionManagementCLI extends Ex
|
|
|
92
92
|
if (!this._extensionManifestPropertiesService.canExecuteOnWorkspace(manifest)
|
|
93
93
|
&& !(isWeb && this._extensionManifestPropertiesService.canExecuteOnWeb(manifest))) {
|
|
94
94
|
this.logger.info(( localize(
|
|
95
|
-
|
|
95
|
+
2454,
|
|
96
96
|
"Cannot install the '{0}' extension because it is declared to not run in this setup.",
|
|
97
97
|
getExtensionId(manifest.publisher, manifest.name)
|
|
98
98
|
)));
|
|
@@ -4,10 +4,10 @@ import { DeferredPromise } from '@codingame/monaco-vscode-api/vscode/vs/base/com
|
|
|
4
4
|
import { Emitter } from '@codingame/monaco-vscode-api/vscode/vs/base/common/event';
|
|
5
5
|
import { Disposable, DisposableMap } from '@codingame/monaco-vscode-api/vscode/vs/base/common/lifecycle';
|
|
6
6
|
import { revive } from '@codingame/monaco-vscode-api/vscode/vs/base/common/marshalling';
|
|
7
|
+
import { Schemas } from '@codingame/monaco-vscode-api/vscode/vs/base/common/network';
|
|
7
8
|
import { escapeRegExpCharacters } from '@codingame/monaco-vscode-api/vscode/vs/base/common/strings';
|
|
8
9
|
import { ThemeIcon } from '@codingame/monaco-vscode-api/vscode/vs/base/common/themables';
|
|
9
10
|
import { URI } from '@codingame/monaco-vscode-api/vscode/vs/base/common/uri';
|
|
10
|
-
import { Schemas } from '@codingame/monaco-vscode-api/vscode/vs/base/common/network';
|
|
11
11
|
import { Range } from '@codingame/monaco-vscode-api/vscode/vs/editor/common/core/range';
|
|
12
12
|
import { getWordAtText } from '@codingame/monaco-vscode-api/vscode/vs/editor/common/core/wordHelper';
|
|
13
13
|
import { CompletionItemKind } from '@codingame/monaco-vscode-api/vscode/vs/editor/common/languages';
|
|
@@ -20,7 +20,7 @@ import { IChatWidgetService } from '@codingame/monaco-vscode-api/vscode/vs/workb
|
|
|
20
20
|
import { IChatAgentService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/chatAgents.service';
|
|
21
21
|
import { IChatEditingService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/chatEditingService.service';
|
|
22
22
|
import { ChatRequestAgentPart } from '@codingame/monaco-vscode-b994942c-360d-5b68-8a33-77d4bde6b714-common/vscode/vs/workbench/contrib/chat/common/chatParserTypes';
|
|
23
|
-
import { ChatRequestParser } from '@codingame/monaco-vscode-
|
|
23
|
+
import { ChatRequestParser } from '@codingame/monaco-vscode-5084de40-f866-5cb5-9d9b-33a10f6f235d-common/vscode/vs/workbench/contrib/chat/common/chatRequestParser';
|
|
24
24
|
import { IChatService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/chatService.service';
|
|
25
25
|
import { ChatModeKind, ChatAgentLocation } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/constants';
|
|
26
26
|
import { extHostNamedCustomer } from '../../services/extensions/common/extHostCustomers.js';
|
|
@@ -129,7 +129,8 @@ let MainThreadChatAgents2 = class MainThreadChatAgents2 extends Disposable {
|
|
|
129
129
|
invoke: async (request, progress, history, token) => {
|
|
130
130
|
this._pendingProgress.set(request.requestId, progress);
|
|
131
131
|
try {
|
|
132
|
-
|
|
132
|
+
const chatSessionContext = this._chatService.getChatSessionFromInternalId(request.sessionId);
|
|
133
|
+
return (await this._proxy.$invokeAgent(handle, request, { history, chatSessionContext }, token)) ?? {};
|
|
133
134
|
}
|
|
134
135
|
finally {
|
|
135
136
|
this._pendingProgress.delete(request.requestId);
|
|
@@ -167,7 +168,7 @@ let MainThreadChatAgents2 = class MainThreadChatAgents2 extends Disposable {
|
|
|
167
168
|
metadata: revive(metadata),
|
|
168
169
|
slashCommands: [],
|
|
169
170
|
disambiguation: [],
|
|
170
|
-
locations: [ChatAgentLocation.
|
|
171
|
+
locations: [ChatAgentLocation.Chat],
|
|
171
172
|
modes: [ChatModeKind.Ask, ChatModeKind.Agent, ChatModeKind.Edit],
|
|
172
173
|
}, impl);
|
|
173
174
|
}
|
|
@@ -177,7 +178,7 @@ let MainThreadChatAgents2 = class MainThreadChatAgents2 extends Disposable {
|
|
|
177
178
|
this._agents.set(handle, {
|
|
178
179
|
id: id,
|
|
179
180
|
extensionId: extension,
|
|
180
|
-
dispose: disposable.dispose,
|
|
181
|
+
dispose: () => disposable.dispose(),
|
|
181
182
|
hasFollowups: metadata.hasFollowups
|
|
182
183
|
});
|
|
183
184
|
}
|
|
@@ -7,7 +7,8 @@ import { IChatAgentRequest } from "@codingame/monaco-vscode-b994942c-360d-5b68-8
|
|
|
7
7
|
import { IChatContentInlineReference, IChatProgress } from "@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/chatService";
|
|
8
8
|
import { ChatSession, IChatSessionHistoryItem } from "@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/chatSessionsService";
|
|
9
9
|
import { IChatSessionsService } from "@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/chatSessionsService.service";
|
|
10
|
-
import { EditorGroupColumn } from "@codingame/monaco-vscode-
|
|
10
|
+
import { EditorGroupColumn } from "@codingame/monaco-vscode-a17e9d37-b6c1-5556-8402-5db73960fae3-common/vscode/vs/workbench/services/editor/common/editorGroupColumn";
|
|
11
|
+
import { IEditorGroupsService } from "@codingame/monaco-vscode-api/vscode/vs/workbench/services/editor/common/editorGroupsService.service";
|
|
11
12
|
import { IEditorService } from "@codingame/monaco-vscode-api/vscode/vs/workbench/services/editor/common/editorService.service";
|
|
12
13
|
import { IExtHostContext } from "../../services/extensions/common/extHostCustomers.js";
|
|
13
14
|
import { Dto } from "@codingame/monaco-vscode-api/vscode/vs/workbench/services/extensions/common/proxyIdentifier";
|
|
@@ -57,6 +58,7 @@ export declare class MainThreadChatSessions extends Disposable implements MainTh
|
|
|
57
58
|
private readonly _chatSessionsService;
|
|
58
59
|
private readonly _dialogService;
|
|
59
60
|
private readonly _editorService;
|
|
61
|
+
private readonly editorGroupService;
|
|
60
62
|
private readonly _logService;
|
|
61
63
|
private readonly _viewsService;
|
|
62
64
|
private readonly _itemProvidersRegistrations;
|
|
@@ -64,9 +66,10 @@ export declare class MainThreadChatSessions extends Disposable implements MainTh
|
|
|
64
66
|
private readonly _activeSessions;
|
|
65
67
|
private readonly _sessionDisposables;
|
|
66
68
|
private readonly _proxy;
|
|
67
|
-
constructor(_extHostContext: IExtHostContext, _chatSessionsService: IChatSessionsService, _dialogService: IDialogService, _editorService: IEditorService, _logService: ILogService, _viewsService: IViewsService);
|
|
69
|
+
constructor(_extHostContext: IExtHostContext, _chatSessionsService: IChatSessionsService, _dialogService: IDialogService, _editorService: IEditorService, editorGroupService: IEditorGroupsService, _logService: ILogService, _viewsService: IViewsService);
|
|
68
70
|
$registerChatSessionItemProvider(handle: number, chatSessionType: string): void;
|
|
69
71
|
$onDidChangeChatSessionItems(handle: number): void;
|
|
72
|
+
$onDidCommitChatSessionItem(handle: number, original: string, modified: string): void;
|
|
70
73
|
private _provideChatSessionItems;
|
|
71
74
|
private _provideNewChatSessionItem;
|
|
72
75
|
private _provideChatSessionContent;
|