Skip to content

Commit 6f4092e

Browse files
committed
rename failed -> installLocally
1 parent b5e74bd commit 6f4092e

File tree

7 files changed

+22
-22
lines changed

7 files changed

+22
-22
lines changed

src/vs/platform/environment/node/argv.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -101,7 +101,7 @@ export const OPTIONS: OptionDescriptions<Required<NativeParsedArgs>> = {
101101
'install-extension': { type: 'string[]', cat: 'e', args: 'ext-id | path', description: localize('installExtension', "Installs or updates an extension. The argument is either an extension id or a path to a VSIX. The identifier of an extension is '${publisher}.${name}'. Use '--force' argument to update to latest version. To install a specific version provide '@${version}'. For example: '[email protected]'.") },
102102
'pre-release': { type: 'boolean', cat: 'e', description: localize('install prerelease', "Installs the pre-release version of the extension, when using --install-extension") },
103103
'uninstall-extension': { type: 'string[]', cat: 'e', args: 'ext-id', description: localize('uninstallExtension', "Uninstalls an extension.") },
104-
'download-extensions-locally': { type: 'boolean', cat: 'e', description: localize('downloadExtensionsLocally', "When enabled extensions are downloaded locally and installed on remote") },
104+
'download-extensions-locally': { type: 'boolean', cat: 'e', description: localize('downloadExtensionsLocally', "When enabled extensions are downloaded locally and then installed on remote") },
105105
'update-extensions': { type: 'boolean', cat: 'e', description: localize('updateExtensions', "Update the installed extensions.") },
106106
'enable-proposed-api': { type: 'string[]', allowEmptyValue: true, cat: 'e', args: 'ext-id', description: localize('experimentalApis', "Enables proposed API features for extensions. Can receive one or more extension IDs to enable individually.") },
107107

src/vs/platform/extensionManagement/common/extensionManagement.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -540,7 +540,7 @@ export class ExtensionManagementError extends Error {
540540
}
541541

542542
export interface InstallExtensionSummary {
543-
failed: {
543+
installLocally: {
544544
id: string;
545545
installOptions: InstallOptions;
546546
}[];

src/vs/server/node/remoteExtensionsScanner.ts

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -29,8 +29,8 @@ export class RemoteExtensionsScannerService implements IRemoteExtensionsScannerS
2929

3030
readonly _serviceBrand: undefined;
3131

32-
private readonly _whenBuiltinExtensionsReady = Promise.resolve<InstallExtensionSummary>({ failed: [] });
33-
private readonly _whenExtensionsReady = Promise.resolve<InstallExtensionSummary>({ failed: [] });
32+
private readonly _whenBuiltinExtensionsReady = Promise.resolve<InstallExtensionSummary>({ installLocally: [] });
33+
private readonly _whenExtensionsReady = Promise.resolve<InstallExtensionSummary>({ installLocally: [] });
3434

3535
constructor(
3636
private readonly _extensionManagementCLI: ExtensionManagementCLI,
@@ -51,10 +51,10 @@ export class RemoteExtensionsScannerService implements IRemoteExtensionsScannerS
5151
.then(() => {
5252
performance.mark('code/server/didInstallBuiltinExtensions');
5353
_logService.trace('Finished installing builtin extensions');
54-
return { failed: [] };
54+
return { installLocally: [] };
5555
}, error => {
5656
_logService.error(error);
57-
return { failed: [] };
57+
return { installLocally: [] };
5858
});
5959
}
6060

@@ -70,7 +70,7 @@ export class RemoteExtensionsScannerService implements IRemoteExtensionsScannerS
7070
_logService.trace('Installing extensions later...');
7171
this._whenExtensionsReady = this._whenBuiltinExtensionsReady
7272
.then(async () => {
73-
return { failed: extensionsToInstall.map(id => ({ id, installOptions })) };
73+
return { installLocally: extensionsToInstall.map(id => ({ id, installOptions })) };
7474
});
7575
return;
7676
}
@@ -80,11 +80,11 @@ export class RemoteExtensionsScannerService implements IRemoteExtensionsScannerS
8080
.then(() => _extensionManagementCLI.installExtensions(this._asExtensionIdOrVSIX(extensionsToInstall), [], installOptions, !!environmentService.args['force']))
8181
.then(async () => {
8282
_logService.trace('Finished installing extensions');
83-
return { failed: [] };
83+
return { installLocally: [] };
8484
}, async error => {
8585
_logService.error(error);
8686

87-
const failed: {
87+
const installLocally: {
8888
id: string;
8989
installOptions: InstallOptions;
9090
}[] = [];
@@ -93,18 +93,18 @@ export class RemoteExtensionsScannerService implements IRemoteExtensionsScannerS
9393
for (const id of this._asExtensionIdOrVSIX(extensionsToInstall)) {
9494
if (typeof id === 'string') {
9595
if (!alreadyInstalled.some(e => areSameExtensions(e.identifier, { id }))) {
96-
failed.push({ id, installOptions });
96+
installLocally.push({ id, installOptions });
9797
}
9898
}
9999
}
100100

101-
if (!failed.length) {
101+
if (!installLocally.length) {
102102
_logService.trace(`No extensions to report as failed`);
103-
return { failed: [] };
103+
return { installLocally: [] };
104104
}
105105

106-
_logService.info(`Relaying the following extensions to install later: ${failed.map(f => f.id).join(', ')}`);
107-
return { failed };
106+
_logService.info(`Relaying the following extensions to install later: ${installLocally.map(f => f.id).join(', ')}`);
107+
return { installLocally };
108108
});
109109
}
110110
}

src/vs/workbench/contrib/extensions/electron-sandbox/remoteExtensionsInit.ts

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -84,8 +84,8 @@ export class InstallRemoteExtensionsContribution implements IWorkbenchContributi
8484
return;
8585
}
8686

87-
const { failed } = await this.remoteExtensionsScannerService.whenExtensionsReady();
88-
if (failed.length === 0) {
87+
const { installLocally } = await this.remoteExtensionsScannerService.whenExtensionsReady();
88+
if (installLocally.length === 0) {
8989
this.logService.trace('No extensions relayed from server');
9090
return;
9191
}
@@ -95,10 +95,10 @@ export class InstallRemoteExtensionsContribution implements IWorkbenchContributi
9595
return;
9696
}
9797

98-
this.logService.info(`Installing '${failed.length}' extensions relayed from server`);
99-
const galleryExtensions = await this.extensionGalleryService.getExtensions(failed.map(({ id }) => ({ id })), CancellationToken.None);
98+
this.logService.info(`Installing '${installLocally.length}' extensions relayed from server`);
99+
const galleryExtensions = await this.extensionGalleryService.getExtensions(installLocally.map(({ id }) => ({ id })), CancellationToken.None);
100100
const installExtensionInfo: InstallExtensionInfo[] = [];
101-
for (const { id, installOptions } of failed) {
101+
for (const { id, installOptions } of installLocally) {
102102
const extension = galleryExtensions.find(e => areSameExtensions(e.identifier, { id }));
103103
if (extension) {
104104
installExtensionInfo.push({

src/vs/workbench/contrib/remote/electron-sandbox/remote.contribution.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -200,7 +200,7 @@ Registry.as<IConfigurationRegistry>(ConfigurationExtensions.Configuration)
200200
properties: {
201201
'remote.downloadExtensionsLocally': {
202202
type: 'boolean',
203-
markdownDescription: nls.localize('remote.downloadExtensionsLocally', "When enabled extensions are downloaded locally and installed on remote."),
203+
markdownDescription: nls.localize('remote.downloadExtensionsLocally', "When enabled extensions are downloaded locally and then installed on remote."),
204204
default: false
205205
},
206206
}

src/vs/workbench/services/remote/common/remoteExtensionsScanner.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ class RemoteExtensionsScannerService implements IRemoteExtensionsScannerService
3636
whenExtensionsReady(): Promise<InstallExtensionSummary> {
3737
return this.withChannel(
3838
channel => channel.call<InstallExtensionSummary>('whenExtensionsReady'),
39-
{ failed: [] }
39+
{ installLocally: [] }
4040
);
4141
}
4242

src/vs/workbench/test/browser/workbenchTestServices.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2171,7 +2171,7 @@ export class TestRemoteAgentService implements IRemoteAgentService {
21712171

21722172
export class TestRemoteExtensionsScannerService implements IRemoteExtensionsScannerService {
21732173
declare readonly _serviceBrand: undefined;
2174-
async whenExtensionsReady(): Promise<InstallExtensionSummary> { return { failed: [] }; }
2174+
async whenExtensionsReady(): Promise<InstallExtensionSummary> { return { installLocally: [] }; }
21752175
scanExtensions(): Promise<IExtensionDescription[]> { throw new Error('Method not implemented.'); }
21762176
}
21772177

0 commit comments

Comments
 (0)