提交 d774ade0 编写于 作者: S Sandeep Somavarapu

rename donot-sync to do-not-sync

上级 27595761
......@@ -86,7 +86,7 @@ export class Main {
} else if (argv['list-extensions']) {
await this.listExtensions(!!argv['show-versions'], argv['category']);
} else if (argv['install-extension']) {
await this.installExtensions(argv['install-extension'], !!argv['force'], !!argv['donot-sync']);
await this.installExtensions(argv['install-extension'], !!argv['force'], !!argv['do-not-sync']);
} else if (argv['uninstall-extension']) {
await this.uninstallExtension(argv['uninstall-extension']);
} else if (argv['locate-extension']) {
......@@ -126,7 +126,7 @@ export class Main {
extensions.forEach(e => console.log(getId(e.manifest, showVersions)));
}
private async installExtensions(extensions: string[], force: boolean, donotSync: boolean): Promise<void> {
private async installExtensions(extensions: string[], force: boolean, doNotSync: boolean): Promise<void> {
const failed: string[] = [];
const installedExtensionsManifests: IExtensionManifest[] = [];
if (extensions.length) {
......@@ -135,7 +135,7 @@ export class Main {
for (const extension of extensions) {
try {
const manifest = await this.installExtension(extension, force, donotSync);
const manifest = await this.installExtension(extension, force, doNotSync);
if (manifest) {
installedExtensionsManifests.push(manifest);
}
......@@ -150,7 +150,7 @@ export class Main {
return failed.length ? Promise.reject(localize('installation failed', "Failed Installing Extensions: {0}", failed.join(', '))) : Promise.resolve();
}
private async installExtension(extension: string, force: boolean, donotSync: boolean): Promise<IExtensionManifest | null> {
private async installExtension(extension: string, force: boolean, doNotSync: boolean): Promise<IExtensionManifest | null> {
if (/\.vsix$/i.test(extension)) {
extension = path.isAbsolute(extension) ? extension : path.join(process.cwd(), extension);
......@@ -158,7 +158,7 @@ export class Main {
const valid = await this.validate(manifest, force);
if (valid) {
return this.extensionManagementService.install(URI.file(extension), donotSync).then(id => {
return this.extensionManagementService.install(URI.file(extension), doNotSync).then(id => {
console.log(localize('successVsixInstall', "Extension '{0}' was successfully installed.", getBaseLabel(extension)));
return manifest;
}, error => {
......@@ -205,7 +205,7 @@ export class Main {
}
console.log(localize('updateMessage', "Updating the extension '{0}' to the version {1}", id, extension.version));
}
await this.installFromGallery(id, extension, donotSync);
await this.installFromGallery(id, extension, doNotSync);
return manifest;
}));
}
......@@ -227,11 +227,11 @@ export class Main {
return true;
}
private async installFromGallery(id: string, extension: IGalleryExtension, donotSync: boolean): Promise<void> {
private async installFromGallery(id: string, extension: IGalleryExtension, doNotSync: boolean): Promise<void> {
console.log(localize('installing', "Installing extension '{0}' v{1}...", id, extension.version));
try {
await this.extensionManagementService.installFromGallery(extension, donotSync);
await this.extensionManagementService.installFromGallery(extension, doNotSync);
console.log(localize('successInstall', "Extension '{0}' v{1} was successfully installed.", id, extension.version));
} catch (error) {
if (isPromiseCanceledError(error)) {
......
......@@ -72,7 +72,7 @@ export interface ParsedArgs {
remote?: string;
'disable-user-env-probe'?: boolean;
'force'?: boolean;
'donot-sync'?: boolean;
'do-not-sync'?: boolean;
'force-user-env'?: boolean;
'sync'?: 'on' | 'off';
......@@ -188,7 +188,7 @@ export const OPTIONS: OptionDescriptions<Required<ParsedArgs>> = {
'file-chmod': { type: 'boolean' },
'driver-verbose': { type: 'boolean' },
'force': { type: 'boolean' },
'donot-sync': { type: 'boolean' },
'do-not-sync': { type: 'boolean' },
'trace': { type: 'boolean' },
'trace-category-filter': { type: 'string' },
'trace-options': { type: 'string' },
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册