From ff57f347de65f9a7e84f5ca4229dcf0a567757b3 Mon Sep 17 00:00:00 2001 From: Bao Tran Date: Tue, 9 Dec 2025 11:28:01 -0500 Subject: [PATCH 1/9] feat: add bundle uninstall command Made-with: Cursor --- messages/bundle_uninstall.md | 46 ++++++ src/commands/package/bundle/uninstall.ts | 142 +++++++++++++++++++ test/commands/bundle/bundleUninstall.test.ts | 131 +++++++++++++++++ 3 files changed, 319 insertions(+) create mode 100644 messages/bundle_uninstall.md create mode 100644 src/commands/package/bundle/uninstall.ts create mode 100644 test/commands/bundle/bundleUninstall.test.ts diff --git a/messages/bundle_uninstall.md b/messages/bundle_uninstall.md new file mode 100644 index 00000000..4342005c --- /dev/null +++ b/messages/bundle_uninstall.md @@ -0,0 +1,46 @@ +# summary + +Uninstall a package bundle version from a target org. + +# description + +Provide the package bundle version ID or alias and the target org to start an uninstall request. Optionally wait for the uninstall to complete. + +# examples + +- Uninstall a bundle version by ID from a specified org: + + <%= config.bin %> <%= command.id %> --bundle 1Q8... --target-org me@example.com + +- Uninstall a bundle version by alias from your default org and wait up to 10 minutes for completion: + + <%= config.bin %> <%= command.id %> --bundle MyBundle@1.2 -w 10 + +# flags.bundle.summary + +ID (starts with 1Q8) or alias of the package bundle version to uninstall. + +# flags.wait.summary + +Number of minutes to wait for the uninstall request to complete. + +# flags.verbose.summary + +Show additional progress while waiting for uninstall to finish. + +# bundleUninstallWaitingStatus + +Waiting %s more minutes for bundle uninstall. Current status: %s + +# bundleUninstallError + +Encountered errors uninstalling the bundle! %s + +# bundleUninstallInProgress + +Bundle uninstall is currently %s. Request Id: %s. Target org: %s + +# bundleUninstallSuccess + +Successfully uninstalled bundle version %s from %s + diff --git a/src/commands/package/bundle/uninstall.ts b/src/commands/package/bundle/uninstall.ts new file mode 100644 index 00000000..7517ae4c --- /dev/null +++ b/src/commands/package/bundle/uninstall.ts @@ -0,0 +1,142 @@ +/* + * Copyright 2026, Salesforce, Inc. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +import { + Flags, + loglevel, + orgApiVersionFlagWithDeprecations, + requiredOrgFlagWithDeprecations, + SfCommand, +} from '@salesforce/sf-plugins-core'; +import { Lifecycle, Messages } from '@salesforce/core'; +import { BundleSObjects, PackageBundleUninstall } from '@salesforce/packaging'; +import { camelCaseToTitleCase, Duration } from '@salesforce/kit'; + +Messages.importMessagesDirectoryFromMetaUrl(import.meta.url); +const messages = Messages.loadMessages('@salesforce/plugin-packaging', 'bundle_uninstall'); + +export type BundleUninstallResult = BundleSObjects.PkgBundleVerUninstallReqResult; + +export class PackageBundleUninstallCommand extends SfCommand { + public static readonly hidden = true; + public static state = 'beta'; + public static readonly summary = messages.getMessage('summary'); + public static readonly description = messages.getMessage('description'); + public static readonly examples = messages.getMessages('examples'); + public static readonly requiresProject = true; + public static readonly flags = { + loglevel, + bundle: Flags.string({ + char: 'b', + summary: messages.getMessage('flags.bundle.summary'), + required: true, + }), + 'target-org': requiredOrgFlagWithDeprecations, + 'api-version': orgApiVersionFlagWithDeprecations, + wait: Flags.integer({ + char: 'w', + summary: messages.getMessage('flags.wait.summary'), + default: 0, + }), + verbose: Flags.boolean({ + summary: messages.getMessage('flags.verbose.summary'), + }), + }; + + public async run(): Promise { + const { flags } = await this.parse(PackageBundleUninstallCommand); + + const targetOrg = flags['target-org']; + const connection = targetOrg.getConnection(flags['api-version']); + + // Set up lifecycle events for progress tracking + Lifecycle.getInstance().on( + 'bundle-uninstall-progress', + // no async methods + // eslint-disable-next-line @typescript-eslint/require-await + async (data: BundleSObjects.PkgBundleVerUninstallReqResult & { remainingWaitTime: Duration }) => { + if ( + data.UninstallStatus !== BundleSObjects.PkgBundleVersionUninstallReqStatus.success && + data.UninstallStatus !== BundleSObjects.PkgBundleVersionUninstallReqStatus.error + ) { + const status = messages.getMessage('bundleUninstallWaitingStatus', [ + data.remainingWaitTime.minutes, + data.UninstallStatus, + ]); + if (flags.verbose) { + this.log(status); + } else { + this.spinner.status = status; + } + } + } + ); + + const pollingOptions = + flags.wait && flags.wait > 0 + ? { polling: { timeout: Duration.minutes(flags.wait), frequency: Duration.seconds(5) } } + : undefined; + + const isSpinnerRunning = flags.wait && flags.wait > 0 && !flags.verbose; + if (isSpinnerRunning) { + this.spinner.start('Uninstalling bundle...'); + } + + let result: BundleSObjects.PkgBundleVerUninstallReqResult; + try { + result = await PackageBundleUninstall.uninstallBundle(connection, this.project!, { + connection, + project: this.project!, + PackageBundleVersion: flags.bundle, + ...pollingOptions, + }); + } catch (error) { + if (isSpinnerRunning) { + this.spinner.stop(); + } + throw error; + } + + if (isSpinnerRunning) { + this.spinner.stop(); + } + + switch (result.UninstallStatus) { + case BundleSObjects.PkgBundleVersionUninstallReqStatus.error: { + const errorText = + result.ValidationError ?? + `Bundle uninstall failed. Request Id: ${result.Id} Target org: ${targetOrg.getUsername() ?? 'target org'}`; + throw messages.createError('bundleUninstallError', [errorText]); + } + case BundleSObjects.PkgBundleVersionUninstallReqStatus.success: { + const bundleVersionId = result.PackageBundleVersionId ?? flags.bundle; + this.log(messages.getMessage('bundleUninstallSuccess', [bundleVersionId, targetOrg.getUsername() ?? ''])); + break; + } + default: + this.log( + messages.getMessage('bundleUninstallInProgress', [ + camelCaseToTitleCase(result.UninstallStatus as string), + result.Id, + targetOrg.getUsername() ?? '', + ]) + ); + } + + return result; + } +} + diff --git a/test/commands/bundle/bundleUninstall.test.ts b/test/commands/bundle/bundleUninstall.test.ts new file mode 100644 index 00000000..01a068de --- /dev/null +++ b/test/commands/bundle/bundleUninstall.test.ts @@ -0,0 +1,131 @@ +/* + * Copyright 2026, Salesforce, Inc. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import { MockTestOrgData, TestContext } from '@salesforce/core/testSetup'; +import { Config } from '@oclif/core'; +import { assert, expect } from 'chai'; +import { BundleSObjects, PackageBundleUninstall } from '@salesforce/packaging'; +import sinon from 'sinon'; +import { SfCommand } from '@salesforce/sf-plugins-core'; +import { PackageBundleUninstallCommand } from '../../../src/commands/package/bundle/uninstall.js'; + +describe('package:bundle:uninstall - tests', () => { + const $$ = new TestContext(); + const testOrg = new MockTestOrgData(); + const config = new Config({ root: import.meta.url }); + + let uninstallStub = $$.SANDBOX.stub(PackageBundleUninstall, 'uninstallBundle'); + let logStub: sinon.SinonStub; + let warnStub: sinon.SinonStub; + + const stubSpinner = (cmd: PackageBundleUninstallCommand) => { + $$.SANDBOX.stub(cmd.spinner, 'start'); + $$.SANDBOX.stub(cmd.spinner, 'stop'); + $$.SANDBOX.stub(cmd.spinner, 'status').value(''); + }; + + before(async () => { + await $$.stubAuths(testOrg); + await config.load(); + }); + + beforeEach(async () => { + logStub = $$.SANDBOX.stub(SfCommand.prototype, 'log'); + warnStub = $$.SANDBOX.stub(SfCommand.prototype, 'warn'); + }); + + afterEach(() => { + $$.restore(); + }); + + it('uninstalls a bundle version successfully', async () => { + const successResult: BundleSObjects.PkgBundleVerUninstallReqResult = { + Id: '1aF000000000001', + UninstallStatus: BundleSObjects.PkgBundleVersionUninstallReqStatus.success, + PackageBundleVersionId: '1Q8000000000001', + InstalledPkgBundleVersionId: '08c000000000001', + ValidationError: '', + CreatedDate: '2025-01-01T00:00:00Z', + CreatedById: '005000000000001', + }; + uninstallStub.resolves(successResult); + + const cmd = new PackageBundleUninstallCommand( + ['-b', 'MyBundle@1.0', '--target-org', testOrg.username], + config + ); + stubSpinner(cmd); + const res = await cmd.run(); + + expect(res).to.deep.equal(successResult); + expect(warnStub.callCount).to.equal(0); + expect(logStub.callCount).to.equal(1); + expect(logStub.args[0]).to.deep.equal([ + `Successfully uninstalled bundle version 1Q8000000000001 from ${testOrg.username}`, + ]); + }); + + it('logs in-progress uninstall status', async () => { + const queuedResult: BundleSObjects.PkgBundleVerUninstallReqResult = { + Id: '1aF000000000002', + UninstallStatus: BundleSObjects.PkgBundleVersionUninstallReqStatus.queued, + PackageBundleVersionId: '1Q8000000000002', + InstalledPkgBundleVersionId: '08c000000000002', + ValidationError: '', + CreatedDate: '2025-01-01T00:00:00Z', + CreatedById: '005000000000002', + }; + uninstallStub = $$.SANDBOX.stub(PackageBundleUninstall, 'uninstallBundle'); + uninstallStub.resolves(queuedResult); + + const cmd = new PackageBundleUninstallCommand(['-b', '1Q8000000000002', '--target-org', testOrg.username], config); + stubSpinner(cmd); + const res = await cmd.run(); + + expect(res).to.deep.equal(queuedResult); + expect(logStub.callCount).to.equal(1); + const msg = String(logStub.args[0][0]).replace(/\r\n/g, '\n'); + expect(msg).to.equal( + `Bundle uninstall is currently Queued. Request Id: 1aF000000000002. Target org: ${testOrg.username}` + ); + }); + + it('throws when uninstall status is error', async () => { + const errorResult: BundleSObjects.PkgBundleVerUninstallReqResult = { + Id: '1aF000000000003', + UninstallStatus: BundleSObjects.PkgBundleVersionUninstallReqStatus.error, + PackageBundleVersionId: '1Q8000000000003', + InstalledPkgBundleVersionId: '08c000000000003', + ValidationError: 'Failed uninstall', + CreatedDate: '2025-01-01T00:00:00Z', + CreatedById: '005000000000003', + }; + uninstallStub = $$.SANDBOX.stub(PackageBundleUninstall, 'uninstallBundle'); + uninstallStub.resolves(errorResult); + + try { + const cmd = new PackageBundleUninstallCommand( + ['-b', '1Q8000000000003', '--target-org', testOrg.username], + config + ); + stubSpinner(cmd); + await cmd.run(); + assert.fail('the above should throw an error'); + } catch (e) { + expect((e as Error).message).to.equal('Encountered errors uninstalling the bundle! Failed uninstall'); + } + }); +}); + From 198fcffce4ddf1fdde720fd697d066644938a548 Mon Sep 17 00:00:00 2001 From: Bao Tran Date: Mon, 1 Dec 2025 13:40:30 -0500 Subject: [PATCH 2/9] feat: add command to list installed package bundles Introduces the command to display all installed package bundles in the target org, including details about each bundle and its associated packages. Updates the command schema and adds relevant messages for user guidance. --- command-snapshot.json | 8 + messages/bundle_installed_list.md | 21 +++ schemas/package-bundle-installed-list.json | 91 ++++++++++++ src/commands/package/bundle/installed/list.ts | 139 ++++++++++++++++++ 4 files changed, 259 insertions(+) create mode 100644 messages/bundle_installed_list.md create mode 100644 schemas/package-bundle-installed-list.json create mode 100644 src/commands/package/bundle/installed/list.ts diff --git a/command-snapshot.json b/command-snapshot.json index d5a270c9..fecd1dd2 100644 --- a/command-snapshot.json +++ b/command-snapshot.json @@ -95,6 +95,14 @@ "flags": ["api-version", "flags-dir", "json", "loglevel", "package-install-request-id", "target-org", "verbose"], "plugin": "@salesforce/plugin-packaging" }, + { + "alias": [], + "command": "package:bundle:installed:list", + "flagAliases": ["apiversion", "targetusername", "u"], + "flagChars": ["o"], + "flags": ["api-version", "flags-dir", "json", "loglevel", "target-org"], + "plugin": "@salesforce/plugin-packaging" + }, { "alias": [], "command": "package:bundle:list", diff --git a/messages/bundle_installed_list.md b/messages/bundle_installed_list.md new file mode 100644 index 00000000..2ae6aed4 --- /dev/null +++ b/messages/bundle_installed_list.md @@ -0,0 +1,21 @@ +# summary + +List all installed package bundles in the target org. + +# description + +Displays information about all package bundles currently installed in the target org, including the bundle details and the associated packages with their expected and actual versions. + +# examples + +- List all installed package bundles in your default org: + + <%= config.bin %> <%= command.id %> + +- List all installed package bundles in a specific org: + + <%= config.bin %> <%= command.id %> --target-org myorg@example.com + +# flags.target-org.summary + +The org to list installed package bundles from. diff --git a/schemas/package-bundle-installed-list.json b/schemas/package-bundle-installed-list.json new file mode 100644 index 00000000..75b67364 --- /dev/null +++ b/schemas/package-bundle-installed-list.json @@ -0,0 +1,91 @@ +{ + "$schema": "http://json-schema.org/draft-07/schema#", + "$ref": "#/definitions/PackageBundleInstalledListResults", + "definitions": { + "PackageBundleInstalledListResults": { + "type": "array", + "items": { + "$ref": "#/definitions/BundleSObjects.InstalledPackageBundleVersion" + } + }, + "BundleSObjects.InstalledPackageBundleVersion": { + "type": "object", + "properties": { + "Id": { + "type": "string" + }, + "BundleName": { + "type": "string" + }, + "BundleId": { + "type": "string" + }, + "BundleVersionId": { + "type": "string" + }, + "BundleVersionName": { + "type": "string" + }, + "MajorVersion": { + "type": "number" + }, + "MinorVersion": { + "type": "number" + }, + "Description": { + "type": "string" + }, + "InstalledDate": { + "type": "string" + }, + "LastUpgradedDate": { + "type": "string" + }, + "Components": { + "type": "array", + "items": { + "$ref": "#/definitions/BundleSObjects.InstalledPackageBundleVersionComponent" + } + } + }, + "required": [ + "Id", + "BundleName", + "BundleId", + "BundleVersionId", + "BundleVersionName", + "MajorVersion", + "MinorVersion", + "Description", + "InstalledDate", + "LastUpgradedDate", + "Components" + ], + "additionalProperties": false + }, + "BundleSObjects.InstalledPackageBundleVersionComponent": { + "type": "object", + "properties": { + "ExpectedPackageName": { + "type": "string" + }, + "ExpectedPackageVersionNumber": { + "type": "string" + }, + "ActualPackageName": { + "type": "string" + }, + "ActualPackageVersionNumber": { + "type": "string" + } + }, + "required": [ + "ExpectedPackageName", + "ExpectedPackageVersionNumber", + "ActualPackageName", + "ActualPackageVersionNumber" + ], + "additionalProperties": false + } + } +} diff --git a/src/commands/package/bundle/installed/list.ts b/src/commands/package/bundle/installed/list.ts new file mode 100644 index 00000000..d27707e5 --- /dev/null +++ b/src/commands/package/bundle/installed/list.ts @@ -0,0 +1,139 @@ +/* + * Copyright 2025, Salesforce, Inc. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +import { + loglevel, + orgApiVersionFlagWithDeprecations, + requiredOrgFlagWithDeprecations, + SfCommand, +} from '@salesforce/sf-plugins-core'; +import { Connection, Messages } from '@salesforce/core'; +import { BundleSObjects, PackageBundleInstalledList } from '@salesforce/packaging'; +import chalk from 'chalk'; + +Messages.importMessagesDirectoryFromMetaUrl(import.meta.url); +const messages = Messages.loadMessages('@salesforce/plugin-packaging', 'bundle_installed_list'); + +export type PackageBundleInstalledListResults = BundleSObjects.InstalledPackageBundleVersion[]; + +export class PackageBundleInstalledListCommand extends SfCommand { + public static readonly hidden = true; + public static state = 'beta'; + public static readonly summary = messages.getMessage('summary'); + public static readonly description = messages.getMessage('description'); + public static readonly examples = messages.getMessages('examples'); + public static readonly flags = { + loglevel, + 'target-org': requiredOrgFlagWithDeprecations, + 'api-version': orgApiVersionFlagWithDeprecations, + }; + + private targetOrgConnection!: Connection; + + private static formatDate(dateString: string): string { + try { + const date = new Date(dateString); + return date.toLocaleDateString('en-US', { year: 'numeric', month: 'short', day: 'numeric' }); + } catch { + return dateString; + } + } + + public async run(): Promise { + const { flags } = await this.parse(PackageBundleInstalledListCommand); + this.targetOrgConnection = flags['target-org'].getConnection(flags['api-version']); + + const results = await PackageBundleInstalledList.getInstalledBundles(this.targetOrgConnection); + + if (results.length === 0) { + this.warn('No installed package bundles found in the target org'); + return results; + } + + // Display each bundle with its own tables + for (const bundle of results) { + // Bundle info table + const bundleInfo = [ + { + Key: 'Bundle Name', + Value: bundle.BundleName, + }, + { + Key: 'Bundle ID', + Value: bundle.BundleId, + }, + { + Key: 'Bundle Version ID', + Value: bundle.BundleVersionId, + }, + { + Key: 'Bundle Version Name', + Value: bundle.BundleVersionName, + }, + { + Key: 'Major Version', + Value: bundle.MajorVersion.toString(), + }, + { + Key: 'Minor Version', + Value: bundle.MinorVersion.toString(), + }, + { + Key: 'Description', + Value: bundle.Description || 'N/A', + }, + { + Key: 'Installed Date', + Value: PackageBundleInstalledListCommand.formatDate(bundle.InstalledDate), + }, + { + Key: 'Last Upgraded Date', + Value: PackageBundleInstalledListCommand.formatDate(bundle.LastUpgradedDate), + }, + ]; + + this.table({ + data: bundleInfo, + overflow: 'wrap', + }); + + // Add spacing + this.log(''); + + // Associated packages table + if (bundle.Components && bundle.Components.length > 0) { + this.log(chalk.blue('Associated Packages')); + const packageData = bundle.Components.map((comp: BundleSObjects.InstalledPackageBundleVersionComponent) => ({ + 'Expected Package': comp.ExpectedPackageName, + 'Expected Package Version Number': comp.ExpectedPackageVersionNumber, + 'Actual Package': comp.ActualPackageName, + 'Actual Package Version Number': comp.ActualPackageVersionNumber, + })); + + this.table({ + data: packageData, + overflow: 'wrap', + }); + } + + // Add spacing between bundles + this.log(''); + this.log(''); + } + + return results; + } +} From 29b0b1416ce0e4d893fe5b5dd13ee27cb3ac3327 Mon Sep 17 00:00:00 2001 From: Bao Tran Date: Mon, 1 Dec 2025 14:40:17 -0500 Subject: [PATCH 3/9] test: bundle installed list plugin test --- .../bundle/bundleInstalledList.test.ts | 263 ++++++++++++++++++ 1 file changed, 263 insertions(+) create mode 100644 test/commands/bundle/bundleInstalledList.test.ts diff --git a/test/commands/bundle/bundleInstalledList.test.ts b/test/commands/bundle/bundleInstalledList.test.ts new file mode 100644 index 00000000..75d0450b --- /dev/null +++ b/test/commands/bundle/bundleInstalledList.test.ts @@ -0,0 +1,263 @@ +/* + * Copyright 2025, Salesforce, Inc. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import { Config } from '@oclif/core'; +import { TestContext, MockTestOrgData } from '@salesforce/core/testSetup'; +import { expect } from 'chai'; +import { PackageBundleInstalledList } from '@salesforce/packaging'; +import { stubSfCommandUx } from '@salesforce/sf-plugins-core'; +import sinon from 'sinon'; +import { PackageBundleInstalledListCommand } from '../../../src/commands/package/bundle/installed/list.js'; + +describe('package:bundle:installed:list - tests', () => { + const $$ = new TestContext(); + const testOrg = new MockTestOrgData(); + let sfCommandStubs: ReturnType; + let getInstalledBundlesStub: sinon.SinonStub; + const config = new Config({ root: import.meta.url }); + + beforeEach(async () => { + await $$.stubAuths(testOrg); + await config.load(); + sfCommandStubs = stubSfCommandUx($$.SANDBOX); + + getInstalledBundlesStub = $$.SANDBOX.stub(PackageBundleInstalledList, 'getInstalledBundles'); + }); + + afterEach(() => { + $$.restore(); + }); + + it('should list installed bundles with components', async () => { + const mockInstalledBundles = [ + { + Id: '1aE000000000001', + BundleName: 'TestBundle', + BundleId: '0Kz000000000001', + BundleVersionId: '05i000000000001', + BundleVersionName: 'ver 1.0', + MajorVersion: 1, + MinorVersion: 0, + Description: 'Test Description', + InstalledDate: '2024-01-01T00:00:00.000+0000', + LastUpgradedDate: '2024-01-01T00:00:00.000+0000', + Components: [ + { + ExpectedPackageName: 'TestPackage', + ExpectedPackageVersionNumber: '1.0.0.1', + ActualPackageName: 'TestPackage', + ActualPackageVersionNumber: '1.0.0.1', + }, + ], + }, + ]; + + const cmd = new PackageBundleInstalledListCommand(['-o', testOrg.username], config); + + getInstalledBundlesStub.resolves(mockInstalledBundles); + + await cmd.run(); + + expect(getInstalledBundlesStub.calledOnce).to.be.true; + // eslint-disable-next-line @typescript-eslint/no-unsafe-member-access + expect(sfCommandStubs.table.called).to.be.true; + // eslint-disable-next-line @typescript-eslint/no-unsafe-member-access + expect(sfCommandStubs.table.callCount).to.equal(2); // One for bundle info, one for components + }); + + it('should list multiple installed bundles', async () => { + const mockInstalledBundles = [ + { + Id: '1aE000000000001', + BundleName: 'TestBundle1', + BundleId: '0Kz000000000001', + BundleVersionId: '05i000000000001', + BundleVersionName: 'ver 1.0', + MajorVersion: 1, + MinorVersion: 0, + Description: '', + InstalledDate: '2024-01-01T00:00:00.000+0000', + LastUpgradedDate: '2024-01-01T00:00:00.000+0000', + Components: [ + { + ExpectedPackageName: 'Package1', + ExpectedPackageVersionNumber: '1.0.0.1', + ActualPackageName: 'Package1', + ActualPackageVersionNumber: '1.0.0.1', + }, + ], + }, + { + Id: '1aE000000000002', + BundleName: 'TestBundle2', + BundleId: '0Kz000000000002', + BundleVersionId: '05i000000000002', + BundleVersionName: 'ver 2.0', + MajorVersion: 2, + MinorVersion: 0, + Description: '', + InstalledDate: '2024-01-02T00:00:00.000+0000', + LastUpgradedDate: '2024-01-02T00:00:00.000+0000', + Components: [ + { + ExpectedPackageName: 'Package2', + ExpectedPackageVersionNumber: '2.0.0.1', + ActualPackageName: 'Package2', + ActualPackageVersionNumber: '2.0.0.1', + }, + ], + }, + ]; + + const cmd = new PackageBundleInstalledListCommand(['-o', testOrg.username], config); + + getInstalledBundlesStub.resolves(mockInstalledBundles); + + await cmd.run(); + + expect(getInstalledBundlesStub.calledOnce).to.be.true; + // eslint-disable-next-line @typescript-eslint/no-unsafe-member-access + expect(sfCommandStubs.table.called).to.be.true; + // eslint-disable-next-line @typescript-eslint/no-unsafe-member-access + expect(sfCommandStubs.table.callCount).to.equal(4); // Two bundles × (info + components) + }); + + it('should handle bundles with version mismatches', async () => { + const mockInstalledBundles = [ + { + Id: '1aE000000000001', + BundleName: 'TestBundle', + BundleId: '0Kz000000000001', + BundleVersionId: '05i000000000001', + BundleVersionName: 'ver 1.0', + MajorVersion: 1, + MinorVersion: 0, + Description: '', + InstalledDate: '2024-01-01T00:00:00.000+0000', + LastUpgradedDate: '2024-01-01T00:00:00.000+0000', + Components: [ + { + ExpectedPackageName: 'TestPackage', + ExpectedPackageVersionNumber: '1.0.0.1', + ActualPackageName: 'TestPackage', + ActualPackageVersionNumber: '2.0.0.1', + }, + ], + }, + ]; + + const cmd = new PackageBundleInstalledListCommand(['-o', testOrg.username], config); + + getInstalledBundlesStub.resolves(mockInstalledBundles); + + await cmd.run(); + + expect(getInstalledBundlesStub.calledOnce).to.be.true; + // eslint-disable-next-line @typescript-eslint/no-unsafe-member-access + expect(sfCommandStubs.table.called).to.be.true; + }); + + it('should handle bundles with uninstalled packages', async () => { + const mockInstalledBundles = [ + { + Id: '1aE000000000001', + BundleName: 'TestBundle', + BundleId: '0Kz000000000001', + BundleVersionId: '05i000000000001', + BundleVersionName: 'ver 1.0', + MajorVersion: 1, + MinorVersion: 0, + Description: '', + InstalledDate: '2024-01-01T00:00:00.000+0000', + LastUpgradedDate: '2024-01-01T00:00:00.000+0000', + Components: [ + { + ExpectedPackageName: 'TestPackage', + ExpectedPackageVersionNumber: '1.0.0.1', + ActualPackageName: 'Uninstalled', + ActualPackageVersionNumber: 'N/A', + }, + ], + }, + ]; + + const cmd = new PackageBundleInstalledListCommand(['-o', testOrg.username], config); + + getInstalledBundlesStub.resolves(mockInstalledBundles); + + await cmd.run(); + + expect(getInstalledBundlesStub.calledOnce).to.be.true; + // eslint-disable-next-line @typescript-eslint/no-unsafe-member-access + expect(sfCommandStubs.table.called).to.be.true; + }); + + it('should show warning when no installed bundles found', async () => { + const cmd = new PackageBundleInstalledListCommand(['-o', testOrg.username], config); + + getInstalledBundlesStub.resolves([]); + + await cmd.run(); + + expect(getInstalledBundlesStub.calledOnce).to.be.true; + // eslint-disable-next-line @typescript-eslint/no-unsafe-member-access + expect(sfCommandStubs.warn.calledOnce).to.be.true; + // eslint-disable-next-line @typescript-eslint/no-unsafe-member-access + expect(sfCommandStubs.warn.firstCall.args[0]).to.include('No installed package bundles found'); + }); + + it('should handle bundles without components', async () => { + const mockInstalledBundles = [ + { + Id: '1aE000000000001', + BundleName: 'TestBundle', + BundleId: '0Kz000000000001', + BundleVersionId: '05i000000000001', + BundleVersionName: 'ver 1.0', + MajorVersion: 1, + MinorVersion: 0, + Description: '', + InstalledDate: '2024-01-01T00:00:00.000+0000', + LastUpgradedDate: '2024-01-01T00:00:00.000+0000', + Components: [], + }, + ]; + + const cmd = new PackageBundleInstalledListCommand(['-o', testOrg.username], config); + + getInstalledBundlesStub.resolves(mockInstalledBundles); + + await cmd.run(); + + expect(getInstalledBundlesStub.calledOnce).to.be.true; + // eslint-disable-next-line @typescript-eslint/no-unsafe-member-access + expect(sfCommandStubs.table.called).to.be.true; + // eslint-disable-next-line @typescript-eslint/no-unsafe-member-access + expect(sfCommandStubs.table.callCount).to.equal(1); // Only bundle info, no components table + }); + + it('should throw error when target org flag is missing', async () => { + const cmd = new PackageBundleInstalledListCommand([], config); + + getInstalledBundlesStub.resolves([]); + + try { + await cmd.run(); + expect.fail('Expected error was not thrown'); + } catch (error) { + expect((error as Error).message).to.include('No default environment found'); + } + }); +}); From 16653fc7566c7a1c77e8b12040ce1c3f5b204892 Mon Sep 17 00:00:00 2001 From: Bao Tran Date: Mon, 15 Dec 2025 15:34:11 -0500 Subject: [PATCH 4/9] chore: remove old bundle install list command --- command-snapshot.json | 16 +-- messages/bundle_install_list.md | 69 ------------ src/commands/package/bundle/install/list.ts | 101 ----------------- .../commands/bundle/bundleInstallList.test.ts | 105 ------------------ 4 files changed, 8 insertions(+), 283 deletions(-) delete mode 100644 messages/bundle_install_list.md delete mode 100644 src/commands/package/bundle/install/list.ts delete mode 100644 test/commands/bundle/bundleInstallList.test.ts diff --git a/command-snapshot.json b/command-snapshot.json index fecd1dd2..36aa6c30 100644 --- a/command-snapshot.json +++ b/command-snapshot.json @@ -79,14 +79,6 @@ "flags": ["api-version", "bundle", "dev-hub-org", "flags-dir", "json", "loglevel", "target-org", "verbose", "wait"], "plugin": "@salesforce/plugin-packaging" }, - { - "alias": [], - "command": "package:bundle:install:list", - "flagAliases": ["apiversion", "targetusername", "u"], - "flagChars": ["c", "o", "s"], - "flags": ["api-version", "created-last-days", "flags-dir", "json", "loglevel", "status", "target-org", "verbose"], - "plugin": "@salesforce/plugin-packaging" - }, { "alias": [], "command": "package:bundle:install:report", @@ -111,6 +103,14 @@ "flags": ["api-version", "flags-dir", "json", "loglevel", "target-dev-hub", "verbose"], "plugin": "@salesforce/plugin-packaging" }, + { + "alias": [], + "command": "package:bundle:uninstall", + "flagAliases": ["apiversion", "targetusername", "u"], + "flagChars": ["b", "o", "w"], + "flags": ["api-version", "bundle", "flags-dir", "json", "loglevel", "target-org", "verbose", "wait"], + "plugin": "@salesforce/plugin-packaging" + }, { "alias": [], "command": "package:bundle:version:create", diff --git a/messages/bundle_install_list.md b/messages/bundle_install_list.md deleted file mode 100644 index b7d9144b..00000000 --- a/messages/bundle_install_list.md +++ /dev/null @@ -1,69 +0,0 @@ -# summary - -List package bundle installation requests. - -# description - -Shows the details of each request to install a package bundle version in the target org. - -All filter parameters are applied using the AND logical operator (not OR). - -To get information about a specific request, run "<%= config.bin %> package bundle install report" and enter the request ID. - -# flags.status.summary - -Status of the installation request, used to filter the list. - -# flags.verbose.summary - -Display additional information, such as the validation text for each package bundle installation request. - -# flags.created-last-days.summary - -Number of days since the request was created, starting at 0. Use 0 for today. - -# examples - -- List all package bundle installation requests in your default Dev Hub org: - - <%= config.bin %> <%= command.id %> - -- List package bundle installation requests from the last 3 days in the Dev Hub org with username devhub@example.com: - - <%= config.bin %> <%= command.id %> --created-last-days 3 --target-dev-hub devhub@example.com - -- List package bundle installation requests with the Error status: - - <%= config.bin %> <%= command.id %> --status Error - -- List package bundle installation requests with the Queued status: - - <%= config.bin %> <%= command.id %> --status Queued - -- List package bundle install requests from today with the Success status: - - <%= config.bin %> <%= command.id %> --created-last-days 0 --status Success - -# id - -ID - -# status - -Status - -# package-bundle-version-id - -Package Bundle Version ID - -# development-organization - -Development Organization - -# created-by - -Created By - -# validation-error - -Validation Error diff --git a/src/commands/package/bundle/install/list.ts b/src/commands/package/bundle/install/list.ts deleted file mode 100644 index 679d279d..00000000 --- a/src/commands/package/bundle/install/list.ts +++ /dev/null @@ -1,101 +0,0 @@ -/* - * Copyright 2026, Salesforce, Inc. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -import { - Flags, - loglevel, - orgApiVersionFlagWithDeprecations, - requiredOrgFlagWithDeprecations, - SfCommand, -} from '@salesforce/sf-plugins-core'; -import { Connection, Messages } from '@salesforce/core'; -import { BundleSObjects, PackageBundleInstall } from '@salesforce/packaging'; -import chalk from 'chalk'; - -Messages.importMessagesDirectoryFromMetaUrl(import.meta.url); -const messages = Messages.loadMessages('@salesforce/plugin-packaging', 'bundle_install_list'); - -type Status = BundleSObjects.PkgBundleVersionInstallReqStatus; -export type PackageBundleInstallRequestResults = BundleSObjects.PkgBundleVersionInstallReqResult[]; - -export class PackageBundleInstallListCommand extends SfCommand { - public static readonly hidden = true; - public static state = 'beta'; - public static readonly summary = messages.getMessage('summary'); - public static readonly description = messages.getMessage('description'); - public static readonly examples = messages.getMessages('examples'); - public static readonly flags = { - loglevel, - 'target-org': requiredOrgFlagWithDeprecations, - 'api-version': orgApiVersionFlagWithDeprecations, - 'created-last-days': Flags.integer({ - char: 'c', - summary: messages.getMessage('flags.created-last-days.summary'), - }), - status: Flags.custom({ - options: [ - BundleSObjects.PkgBundleVersionInstallReqStatus.queued, - BundleSObjects.PkgBundleVersionInstallReqStatus.inProgress, - BundleSObjects.PkgBundleVersionInstallReqStatus.success, - BundleSObjects.PkgBundleVersionInstallReqStatus.error, - ], - })({ - char: 's', - summary: messages.getMessage('flags.status.summary'), - }), - verbose: Flags.boolean({ - summary: messages.getMessage('flags.verbose.summary'), - }), - }; - - private connection!: Connection; - - public async run(): Promise { - const { flags } = await this.parse(PackageBundleInstallListCommand); - this.connection = flags['target-org'].getConnection(flags['api-version']); - const results = await PackageBundleInstall.getInstallStatuses( - this.connection, - flags.status, - flags['created-last-days'] - ); - - if (results.length === 0) { - this.warn('No results found'); - } else { - const data = results.map((r) => ({ - Id: r.Id ?? 'N/A', - Status: r.InstallStatus ?? 'Unknown', - 'Package Bundle Version Id': r.PackageBundleVersionId ?? 'N/A', - 'Development Organization': r.DevelopmentOrganization ?? 'N/A', - 'Created Date': r.CreatedDate ?? 'N/A', - 'Created By': r.CreatedById ?? 'N/A', - ...(flags.verbose - ? { - 'Validation Error': r.ValidationError ?? 'N/A', - } - : {}), - })); - - this.table({ - data, - overflow: 'wrap', - title: chalk.blue(`Package Bundle Install Requests [${results.length}]`), - }); - } - - return results; - } -} diff --git a/test/commands/bundle/bundleInstallList.test.ts b/test/commands/bundle/bundleInstallList.test.ts deleted file mode 100644 index 11c759b1..00000000 --- a/test/commands/bundle/bundleInstallList.test.ts +++ /dev/null @@ -1,105 +0,0 @@ -/* - * Copyright 2026, Salesforce, Inc. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -import { Config } from '@oclif/core'; -import { TestContext, MockTestOrgData } from '@salesforce/core/testSetup'; -import { expect } from 'chai'; -import { PackageBundleInstall, BundleSObjects } from '@salesforce/packaging'; -import { stubSfCommandUx } from '@salesforce/sf-plugins-core'; -import sinon from 'sinon'; -import { PackageBundleInstallListCommand } from '../../../src/commands/package/bundle/install/list.js'; - -describe('package:bundle:install:list - tests', () => { - const $$ = new TestContext(); - const testOrg = new MockTestOrgData(); - let sfCommandStubs: ReturnType; - let getInstallStatusesStub: sinon.SinonStub; - const config = new Config({ root: import.meta.url }); - - beforeEach(async () => { - await $$.stubAuths(testOrg); - await config.load(); - sfCommandStubs = stubSfCommandUx($$.SANDBOX); - - getInstallStatusesStub = $$.SANDBOX.stub(PackageBundleInstall, 'getInstallStatuses'); - }); - - afterEach(() => { - $$.restore(); - }); - - it('should list bundle install requests', async () => { - const cmd = new PackageBundleInstallListCommand(['--target-org', testOrg.username], config); - - const mockResults: BundleSObjects.PkgBundleVersionInstallReqResult[] = [ - { - Id: 'test-id-1', - InstallStatus: BundleSObjects.PkgBundleVersionInstallReqStatus.success, - PackageBundleVersionId: 'bundle-version-id-1', - DevelopmentOrganization: 'dev-org-1', - CreatedDate: '2023-01-01T00:00:00Z', - CreatedById: 'user-id-1', - ValidationError: '', - Error: [], - }, - ]; - - getInstallStatusesStub.resolves(mockResults); - - await cmd.run(); - - // eslint-disable-next-line @typescript-eslint/no-unsafe-member-access - expect(sfCommandStubs.table.calledOnce).to.be.true; - expect(getInstallStatusesStub.calledOnce).to.be.true; - }); - - it('should show warning when no results found', async () => { - const cmd = new PackageBundleInstallListCommand(['--target-org', testOrg.username], config); - - getInstallStatusesStub.resolves([]); - - await cmd.run(); - - // eslint-disable-next-line @typescript-eslint/no-unsafe-member-access - expect(sfCommandStubs.warn.calledOnce).to.be.true; - expect(sfCommandStubs.warn.firstCall.args[0]).to.equal('No results found'); - }); - - // This test does very little to test the verbose command except make sure that it is there. - it('should handle verbose flag', async () => { - const cmd = new PackageBundleInstallListCommand(['--target-org', testOrg.username, '--verbose'], config); - - const mockResults: BundleSObjects.PkgBundleVersionInstallReqResult[] = [ - { - Id: 'test-id-1', - InstallStatus: BundleSObjects.PkgBundleVersionInstallReqStatus.error, - PackageBundleVersionId: 'bundle-version-id-1', - DevelopmentOrganization: 'dev-org-1', - CreatedDate: '2023-01-01T00:00:00Z', - CreatedById: 'user-id-1', - ValidationError: 'Installation failed', - Error: ['Test error'], - }, - ]; - - getInstallStatusesStub.resolves(mockResults); - - await cmd.run(); - - // eslint-disable-next-line @typescript-eslint/no-unsafe-member-access - expect(sfCommandStubs.table.calledOnce).to.be.true; - expect(getInstallStatusesStub.calledOnce).to.be.true; - }); -}); From 62d690a54854cf1194e1c1252c6e242c60b0a374 Mon Sep 17 00:00:00 2001 From: "b.tran" Date: Tue, 24 Mar 2026 10:59:36 -0400 Subject: [PATCH 5/9] chore: fix copyright headers to 2026 Made-with: Cursor --- src/commands/package/bundle/installed/list.ts | 2 +- test/commands/bundle/bundleInstalledList.test.ts | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/commands/package/bundle/installed/list.ts b/src/commands/package/bundle/installed/list.ts index d27707e5..790fa86f 100644 --- a/src/commands/package/bundle/installed/list.ts +++ b/src/commands/package/bundle/installed/list.ts @@ -1,5 +1,5 @@ /* - * Copyright 2025, Salesforce, Inc. + * Copyright 2026, Salesforce, Inc. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/test/commands/bundle/bundleInstalledList.test.ts b/test/commands/bundle/bundleInstalledList.test.ts index 75d0450b..ed23354e 100644 --- a/test/commands/bundle/bundleInstalledList.test.ts +++ b/test/commands/bundle/bundleInstalledList.test.ts @@ -1,5 +1,5 @@ /* - * Copyright 2025, Salesforce, Inc. + * Copyright 2026, Salesforce, Inc. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. From 532b8c64ba81bf3d741db7b74a57221cc8b56072 Mon Sep 17 00:00:00 2001 From: "b.tran" Date: Fri, 27 Mar 2026 13:35:27 -0400 Subject: [PATCH 6/9] chore: update dependencies and fix INSTALL_URL_BASE usage - Bumped @salesforce/core from ^8.27.0 to ^8.27.1. - Updated AWS SDK dependencies to their latest versions. - Changed INSTALL_URL_BASE usage from .toString() to .href in multiple files for consistency. --- package.json | 2 +- src/commands/package/convert.ts | 2 +- src/commands/package/version/create.ts | 4 +- src/commands/package/version/create/report.ts | 2 +- src/commands/package/version/list.ts | 2 +- yarn.lock | 1209 +++++++---------- 6 files changed, 480 insertions(+), 741 deletions(-) diff --git a/package.json b/package.json index 37ae5052..7609361b 100644 --- a/package.json +++ b/package.json @@ -8,7 +8,7 @@ "o11yUploadEndpoint": "https://794testsite.my.site.com/byolwr/webruntime/log/metrics", "dependencies": { "@oclif/core": "^4", - "@salesforce/core": "^8.27.0", + "@salesforce/core": "^8.27.1", "@salesforce/kit": "^3.2.4", "@salesforce/packaging": "^4.21.5", "@salesforce/sf-plugins-core": "^12.2.6", diff --git a/src/commands/package/convert.ts b/src/commands/package/convert.ts index 05093b8f..4a6eeb7b 100644 --- a/src/commands/package/convert.ts +++ b/src/commands/package/convert.ts @@ -159,7 +159,7 @@ export class PackageConvert extends SfCommand const successMessage = pvcMessages.getMessage(result.Status, [ result.Id, result.SubscriberPackageVersionId, - INSTALL_URL_BASE.toString(), + INSTALL_URL_BASE.href, result.SubscriberPackageVersionId, this.config.bin, ]); diff --git a/src/commands/package/version/create.ts b/src/commands/package/version/create.ts index 40b42376..93e802f6 100644 --- a/src/commands/package/version/create.ts +++ b/src/commands/package/version/create.ts @@ -284,7 +284,7 @@ export class PackageVersionCreateCommand extends SfCommand'}` + ? `${pkgUtils.INSTALL_URL_BASE.href}${record.SubscriberPackageVersionId ?? ''}` : ''; const data = [ diff --git a/src/commands/package/version/list.ts b/src/commands/package/version/list.ts index e5fddf71..19be78f0 100644 --- a/src/commands/package/version/list.ts +++ b/src/commands/package/version/list.ts @@ -208,7 +208,7 @@ export class PackageVersionListCommand extends SfCommand= 2.1.2 < 3.0.0" @@ -5823,13 +5579,6 @@ jackspeak@^3.1.2: optionalDependencies: "@pkgjs/parseargs" "^0.11.0" -jackspeak@^4.1.1: - version "4.1.1" - resolved "https://registry.yarnpkg.com/jackspeak/-/jackspeak-4.1.1.tgz#96876030f450502047fc7e8c7fcf8ce8124e43ae" - integrity sha512-zptv57P3GpL+O0I7VdMJNBZCu+BPHVQUk55Ft8/QCJjTVxrnJHuVuX/0Bl2A6/+2oyR/ZMEuFKwmzqqZ/U5nPQ== - dependencies: - "@isaacs/cliui" "^8.0.2" - jake@^10.8.5: version "10.9.4" resolved "https://registry.yarnpkg.com/jake/-/jake-10.9.4.tgz#d626da108c63d5cfb00ab5c25fadc7e0084af8e6" @@ -6235,11 +5984,6 @@ lru-cache@^10.0.1, lru-cache@^10.2.0: resolved "https://registry.yarnpkg.com/lru-cache/-/lru-cache-10.4.3.tgz#410fc8a17b70e598013df257c2446b7f3383f119" integrity sha512-JNAzZcXrCt42VGLuYz0zfAzDfAvJWW6AfYlDBQyDV5DClI2m5sAmK+OIO7s59XfsRsWHp02jAJrRadPRGTt6SQ== -lru-cache@^11.0.0: - version "11.2.2" - resolved "https://registry.yarnpkg.com/lru-cache/-/lru-cache-11.2.2.tgz#40fd37edffcfae4b2940379c0722dc6eeaa75f24" - integrity sha512-F9ODfyqML2coTIsQpSkRHnLSZMtkU8Q+mSfcaIyKwy58u+8k5nvAYeiNhsyMARvzNcXJ9QfWVrcPsC9e9rAxtg== - lru-cache@^5.1.1: version "5.1.1" resolved "https://registry.yarnpkg.com/lru-cache/-/lru-cache-5.1.1.tgz#1da27e6710271947695daf6848e847f01d84b920" @@ -6294,9 +6038,9 @@ map-obj@^4.0.0: integrity sha512-hdN1wVrZbb29eBGiGjJbeP8JbKjq1urkHJ/LIP/NY48MZ1QVXUsQBV1G1zvYFHn1XE06cwjBsOI2K3Ulnj1YXQ== markdown-it@^14.1.0: - version "14.1.0" - resolved "https://registry.yarnpkg.com/markdown-it/-/markdown-it-14.1.0.tgz#3c3c5992883c633db4714ccb4d7b5935d98b7d45" - integrity sha512-a54IwgWPaeBCAAsv13YgmALOF1elABB08FxO9i+r4VFk5Vl4pKokRPeX8u5TCgSsPi6ec1otfLjdOpVcgbpshg== + version "14.1.1" + resolved "https://registry.yarnpkg.com/markdown-it/-/markdown-it-14.1.1.tgz#856f90b66fc39ae70affd25c1b18b581d7deee1f" + integrity sha512-BuU2qnTti9YKgK5N+IeMubp14ZUKUUw7yeJbkjtosvHiP0AZ5c8IAgEMk79D0eC8F23r4Ac/q8cAIFdm2FtyoA== dependencies: argparse "^2.0.1" entities "^4.4.0" @@ -6473,7 +6217,7 @@ minimatch@9.0.3: dependencies: brace-expansion "^2.0.1" -minimatch@^10.1.1, minimatch@^10.2.4: +minimatch@^10.2.4: version "10.2.4" resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-10.2.4.tgz#465b3accbd0218b8281f5301e27cedc697f96fde" integrity sha512-oRjTw/97aTBN0RHbYCdtF1MQfvusSIBQM0IZEgzl6426+8jSC0nF1a/GmnVLpfB9yyr6g6FTqWqiZVbxrtaCIg== @@ -6481,25 +6225,25 @@ minimatch@^10.1.1, minimatch@^10.2.4: brace-expansion "^5.0.2" minimatch@^3.0.4, minimatch@^3.0.5, minimatch@^3.1.1, minimatch@^3.1.2: - version "3.1.2" - resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-3.1.2.tgz#19cd194bfd3e428f049a70817c038d89ab4be35b" - integrity sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw== + version "3.1.5" + resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-3.1.5.tgz#580c88f8d5445f2bd6aa8f3cadefa0de79fbd69e" + integrity sha512-VgjWUsnnT6n+NUk6eZq77zeFdpW2LWDzP6zFGrCbHXiYNul5Dzqk2HHQ5uFH2DNW5Xbp8+jVzaeNt94ssEEl4w== dependencies: brace-expansion "^1.1.7" minimatch@^5.0.1, minimatch@^5.1.6: - version "5.1.6" - resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-5.1.6.tgz#1cfcb8cf5522ea69952cd2af95ae09477f122a96" - integrity sha512-lKwV/1brpG6mBUFHtb7NUmtABCb2WZZmm2wNiOA5hAb8VdCS4B3dtMWyvcoViccwAW/COERjXLt0zP1zXUN26g== + version "5.1.9" + resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-5.1.9.tgz#1293ef15db0098b394540e8f9f744f9fda8dee4b" + integrity sha512-7o1wEA2RyMP7Iu7GNba9vc0RWWGACJOCZBJX2GJWip0ikV+wcOsgVuY9uE8CPiyQhkGFSlhuSkZPavN7u1c2Fw== dependencies: brace-expansion "^2.0.1" minimatch@^9.0.4, minimatch@^9.0.5: - version "9.0.5" - resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-9.0.5.tgz#d74f9dd6b57d83d8e98cfb82133b03978bc929e5" - integrity sha512-G6T0ZX48xgozx7587koeX9Ys2NYy6Gmv//P89sEte9V9whIapMNF4idKxnW2QtCcLiTWlb/wfCabAtAFWhhBow== + version "9.0.9" + resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-9.0.9.tgz#9b0cb9fcb78087f6fd7eababe2511c4d3d60574e" + integrity sha512-OBwBN9AL4dqmETlpS2zasx+vTeWclWzkblfZk7KTA5j3jeOONz/tRCnZomUyvNg83wL5Zv9Ss6HMJXAgL8R2Yg== dependencies: - brace-expansion "^2.0.1" + brace-expansion "^2.0.2" minimist-options@4.1.0: version "4.1.0" @@ -6516,9 +6260,9 @@ minimist@^1.2.0, minimist@^1.2.5, minimist@^1.2.6: integrity sha512-2yyAR8qBkN3YuheJanUpWC5U3bb5osDywNB8RzDVlDwDHbocAJveqqj1u8+SVD7jkWT4yvsHCpWqqWqAxb0zCA== "minipass@^5.0.0 || ^6.0.2 || ^7.0.0", minipass@^7.1.2: - version "7.1.2" - resolved "https://registry.yarnpkg.com/minipass/-/minipass-7.1.2.tgz#93a9626ce5e5e66bd4db86849e7515e92340a707" - integrity sha512-qOOzS1cBTWYF4BH8fVePDBOO9iptMnGUEZwNc/cMWnTV2nVLZ7VoNWEPHkYczZA0pdoA7dl6e7FL659nX9S2aw== + version "7.1.3" + resolved "https://registry.yarnpkg.com/minipass/-/minipass-7.1.3.tgz#79389b4eb1bb2d003a9bba87d492f2bd37bdc65b" + integrity sha512-tEBHqDnIoM/1rXME1zgka9g6Q2lcoCkxHLuc7ODJ5BxbP5d4c2Z5cGgtXAku59200Cx7diuHTOYfSBD8n6mm8A== mnemonist@^0.39.0: version "0.39.8" @@ -6646,9 +6390,9 @@ node-preload@^0.2.1: process-on-spawn "^1.0.0" node-releases@^2.0.27: - version "2.0.27" - resolved "https://registry.yarnpkg.com/node-releases/-/node-releases-2.0.27.tgz#eedca519205cf20f650f61d56b070db111231e4e" - integrity sha512-nmh3lCkYZ3grZvqcCH+fjmQ7X+H0OeZgP40OierEaAptX4XofMh5kwNbWh7lBduUzCcV/8kZ+NDLCwm2iorIlA== + version "2.0.36" + resolved "https://registry.yarnpkg.com/node-releases/-/node-releases-2.0.36.tgz#99fd6552aaeda9e17c4713b57a63964a2e325e9d" + integrity sha512-TdC8FSgHz8Mwtw9g5L4gR/Sh9XhSP/0DEkQxfEFXOpiul5IiHgHan2VhYYb6agDSfp4KuvltmGApc8HMgUrIkA== normalize-package-data@^2.5.0: version "2.5.0" @@ -6690,9 +6434,9 @@ normalize-url@^6.0.1: integrity sha512-DlL+XwOy3NxAQ8xuC0okPgK46iuVNAK01YN7RueYBqqFeGsBjV9XmCAzAdgt+667bCl5kPh9EqKKDwnaPG1I7A== normalize-url@^8.0.0: - version "8.1.0" - resolved "https://registry.yarnpkg.com/normalize-url/-/normalize-url-8.1.0.tgz#d33504f67970decf612946fd4880bc8c0983486d" - integrity sha512-X06Mfd/5aKsRHc0O0J5CUedwnPmnDtLF2+nq+KN9KSDlJHkPuh0JUviWjEWMe0SW/9TDdSLVPuk7L5gGTIA1/w== + version "8.1.1" + resolved "https://registry.yarnpkg.com/normalize-url/-/normalize-url-8.1.1.tgz#751a20c8520e5725404c06015fea21d7567f25ef" + integrity sha512-JYc0DPlpGWB40kH5g07gGTrYuMqV653k3uBKY6uITPWds3M0ov3GaWGp9lbE3Bzngx8+XkfzgvASb9vk9JDFXQ== npm-run-path@^4.0.0, npm-run-path@^4.0.1: version "4.0.1" @@ -6801,19 +6545,19 @@ obliterator@^2.0.1: integrity sha512-42CPE9AhahZRsMNslczq0ctAEtqk8Eka26QofnqC346BZdHDySk3LWka23LI7ULIw11NmltpiLagIq8gBozxTw== oclif@^4.22.93: - version "4.22.93" - resolved "https://registry.yarnpkg.com/oclif/-/oclif-4.22.93.tgz#45a95adb76d4d0a29764b9affb5150c2b8df6cb1" - integrity sha512-x7FjnZOTuKl4p6KsWFZ2nCH3jQv0EU7+fG+udUHgV+CnXx6xGgCGPfkkDv3jYzjlcW7v1P62f3Ab8hudR0zrnA== + version "4.22.96" + resolved "https://registry.yarnpkg.com/oclif/-/oclif-4.22.96.tgz#a5adc7d64947c65df17b31c5f05463d187707efa" + integrity sha512-aWM9cMb7Q3KW09qi5Mkw0Hq9sIM7DjVlyMAUl8Q2FP3+e5afBlUU9vmL3EJazVPhqcbg5u18E3z+6kCMk72KYw== dependencies: "@aws-sdk/client-cloudfront" "3.1009.0" - "@aws-sdk/client-s3" "3.1009.0" + "@aws-sdk/client-s3" "3.1014.0" "@inquirer/confirm" "^3.1.22" "@inquirer/input" "^2.2.4" "@inquirer/select" "^2.5.0" "@oclif/core" "4.9.0" "@oclif/plugin-help" "^6.2.38" - "@oclif/plugin-not-found" "^3.2.75" - "@oclif/plugin-warn-if-update-available" "^3.1.55" + "@oclif/plugin-not-found" "^3.2.76" + "@oclif/plugin-warn-if-update-available" "^3.1.57" ansis "^3.16.0" async-retry "^1.3.3" change-case "^4" @@ -7058,14 +6802,6 @@ path-scurry@^1.11.1: lru-cache "^10.2.0" minipass "^5.0.0 || ^6.0.2 || ^7.0.0" -path-scurry@^2.0.0: - version "2.0.1" - resolved "https://registry.yarnpkg.com/path-scurry/-/path-scurry-2.0.1.tgz#4b6572376cfd8b811fca9cd1f5c24b3cbac0fe10" - integrity sha512-oWyT4gICAu+kaA7QWk/jvCHWarMKNs6pXOGWKDTr7cw4IGcUbW+PeTfbaQiLGheFRpjo6O9J0PmyMfQPjH71oA== - dependencies: - lru-cache "^11.0.0" - minipass "^7.1.2" - path-to-regexp@^1.7.0: version "1.9.0" resolved "https://registry.yarnpkg.com/path-to-regexp/-/path-to-regexp-1.9.0.tgz#5dc0753acbf8521ca2e0f137b4578b917b10cf24" @@ -7099,19 +6835,19 @@ picocolors@^1.0.0, picocolors@^1.1.1: integrity sha512-xceH2snhtb5M9liqDsmEw56le376mTZkEX/jEb/RxNFyegNul7eNslCXP9FDj/Lcu0X8KEyMceP2ntpaHrDEVA== picomatch@^2.0.4, picomatch@^2.2.1, picomatch@^2.3.1: - version "2.3.1" - resolved "https://registry.yarnpkg.com/picomatch/-/picomatch-2.3.1.tgz#3ba3833733646d9d3e4995946c1365a67fb07a42" - integrity sha512-JU3teHTNjmE2VCGFzuY8EXzCDVwEqB2a8fsIvwaStHhAWJEeVd1o1QD80CU6+ZdEXXSLbSsuLwJjkCBWqRQUVA== + version "2.3.2" + resolved "https://registry.yarnpkg.com/picomatch/-/picomatch-2.3.2.tgz#5a942915e26b372dc0f0e6753149a16e6b1c5601" + integrity sha512-V7+vQEJ06Z+c5tSye8S+nHUfI51xoXIXjHQ99cQtKUkQqqO1kO/KCJUfZXuB47h/YBlDhah2H3hdUGXn8ie0oA== picomatch@^3.0.1: - version "3.0.1" - resolved "https://registry.yarnpkg.com/picomatch/-/picomatch-3.0.1.tgz#817033161def55ec9638567a2f3bbc876b3e7516" - integrity sha512-I3EurrIQMlRc9IaAZnqRR044Phh2DXY+55o7uJ0V+hYZAcQYSuFWsc9q5PvyDHUSCe1Qxn/iBz+78s86zWnGag== + version "3.0.2" + resolved "https://registry.yarnpkg.com/picomatch/-/picomatch-3.0.2.tgz#8f543c114ddc037eab6b10fbd5a66cc8a51a02bc" + integrity sha512-cfDHL6LStTEKlNilboNtobT/kEa30PtAf2Q1OgszfrG/rpVl1xaFWT9ktfkS306GmHgmnad1Sw4wabhlvFtsTw== picomatch@^4.0.3: - version "4.0.3" - resolved "https://registry.yarnpkg.com/picomatch/-/picomatch-4.0.3.tgz#796c76136d1eead715db1e7bad785dedd695a042" - integrity sha512-5gTmgEY/sqK6gFXLIsQNH19lWb4ebPDLA4SdLP7dsWkIXHWlG66oPuVvXSGFPppYZz8ZDZq0dYYrbHfBCVUb1Q== + version "4.0.4" + resolved "https://registry.yarnpkg.com/picomatch/-/picomatch-4.0.4.tgz#fd6f5e00a143086e074dffe4c924b8fb293b0589" + integrity sha512-QP88BAKvMam/3NxH6vj2o21R6MjxZUAd6nlwAS/pnGvN9IVLocLHxGYIzFhg6fUQ+5th6P4dv4eW9jX3DSIj7A== pino-abstract-transport@^1.2.0: version "1.2.0" @@ -7149,9 +6885,9 @@ pino-pretty@^11.3.0: strip-json-comments "^3.1.1" pino-std-serializers@^7.0.0: - version "7.0.0" - resolved "https://registry.yarnpkg.com/pino-std-serializers/-/pino-std-serializers-7.0.0.tgz#7c625038b13718dbbd84ab446bd673dc52259e3b" - integrity sha512-e906FRY0+tV27iq4juKzSYPbUj2do2X2JX4EzSca1631EB2QJQUqGbDuERal7LCtOpxl6x3+nvo9NPZcmjkiFA== + version "7.1.0" + resolved "https://registry.yarnpkg.com/pino-std-serializers/-/pino-std-serializers-7.1.0.tgz#a7b0cd65225f29e92540e7853bd73b07479893fc" + integrity sha512-BndPH67/JxGExRgiX1dX0w1FvZck5Wa4aal9198SrRhZjH3GxKQUKIBnYJTdj2HDN3UQAS06HlfcSbQj2OHmaw== pino@^9.7.0: version "9.14.0" @@ -7271,9 +7007,9 @@ proxy-from-env@^1.1.0: integrity sha512-D+zkORCbA9f1tdWRK0RaCR3GPv50cMxcrz4X8k5LTSUD1Dkw47mKJEZQNunItRTkWwgtaUSo1RVFRIG9ZXiFYg== pump@^3.0.0: - version "3.0.3" - resolved "https://registry.yarnpkg.com/pump/-/pump-3.0.3.tgz#151d979f1a29668dc0025ec589a455b53282268d" - integrity sha512-todwxLMY7/heScKmntwQG8CXVkWUOdYxIvY2s0VWAAMh/nd8SoYiRaKjlr7+iCs984f2P8zvrfWcDDYVb73NfA== + version "3.0.4" + resolved "https://registry.yarnpkg.com/pump/-/pump-3.0.4.tgz#1f313430527fa8b905622ebd22fe1444e757ab3c" + integrity sha512-VS7sjc6KR7e1ukRFhQSY5LM2uBWAUPiOPa/A3mkKmiMwSmRFUITt0xuj+/lesgnCv+dPIEYlkzrcyXgquIHMcA== dependencies: end-of-stream "^1.1.0" once "^1.3.1" @@ -7627,9 +7363,9 @@ safe-stable-stringify@^2.3.1, safe-stable-stringify@^2.4.3: integrity sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg== sax@>=0.6.0: - version "1.4.3" - resolved "https://registry.yarnpkg.com/sax/-/sax-1.4.3.tgz#fcebae3b756cdc8428321805f4b70f16ec0ab5db" - integrity sha512-yqYn1JhPczigF94DMS+shiDMjDowYO6y9+wB/4WgO0Y19jWYk0lQ4tuG5KI7kj4FTp1wxPj5IFfcrz/s1c3jjQ== + version "1.6.0" + resolved "https://registry.yarnpkg.com/sax/-/sax-1.6.0.tgz#da59637629307b97e7c4cb28e080a7bc38560d5b" + integrity sha512-6R3J5M4AcbtLUdZmRv2SygeVaM7IhrLXu9BmnOGmmACak8fiUtOsYNWUS4uK7upbmHIBbLBeFeI//477BKLBzA== scheduler@^0.23.0, scheduler@^0.23.2: version "0.23.2" @@ -7744,7 +7480,15 @@ shebang-regex@^3.0.0: resolved "https://registry.yarnpkg.com/shebang-regex/-/shebang-regex-3.0.0.tgz#ae16f1644d873ecad843b0307b143362d4c42172" integrity sha512-7++dFhtcx3353uBaq8DDR4NuxBetBzC7ZQOhmTQInHEd6bSrXdiEyzCvG07Z44UYdLShWUyXt5M/yhz8ekcb1A== -shelljs@^0.8.4, shelljs@^0.8.5: +shelljs@^0.10.0: + version "0.10.0" + resolved "https://registry.yarnpkg.com/shelljs/-/shelljs-0.10.0.tgz#e3bbae99b0f3f0cc5dce05b46a346fae2090e883" + integrity sha512-Jex+xw5Mg2qMZL3qnzXIfaxEtBaC4n7xifqaqtrZDdlheR70OGkydrPJWT0V1cA1k3nanC86x9FwAmQl6w3Klw== + dependencies: + execa "^5.1.1" + fast-glob "^3.3.2" + +shelljs@^0.8.5: version "0.8.5" resolved "https://registry.yarnpkg.com/shelljs/-/shelljs-0.8.5.tgz#de055408d8361bed66c669d2f000538ced8ee20c" integrity sha512-TiwcRcrkhHvbrZbnRcFYMLl30Dfov3HKqzp5tO5b4pt6G/SezKcYhmDg15zXVBswHmctSAQKznqNW2LO5tTDow== @@ -7898,9 +7642,9 @@ socks@^2.8.3: smart-buffer "^4.2.0" sonic-boom@^4.0.1: - version "4.2.0" - resolved "https://registry.yarnpkg.com/sonic-boom/-/sonic-boom-4.2.0.tgz#e59a525f831210fa4ef1896428338641ac1c124d" - integrity sha512-INb7TM37/mAcsGmc9hyyI6+QR3rR1zVRu36B0NeGXKnOOLiZOfER5SA+N7X7k3yUYRzLWafduTDvJAfDswwEww== + version "4.2.1" + resolved "https://registry.yarnpkg.com/sonic-boom/-/sonic-boom-4.2.1.tgz#28598250df4899c0ac572d7e2f0460690ba6a030" + integrity sha512-w6AxtubXa2wTXAUsZMMWERrsIRAdrK0Sc+FUytWvYAhBJLyuI4llrMIC1DtlNSdI99EI86KZum2MMq3EAZlF9Q== dependencies: atomic-sleep "^1.0.0" @@ -7983,9 +7727,9 @@ spdx-expression-parse@^4.0.0: spdx-license-ids "^3.0.0" spdx-license-ids@^3.0.0: - version "3.0.22" - resolved "https://registry.yarnpkg.com/spdx-license-ids/-/spdx-license-ids-3.0.22.tgz#abf5a08a6f5d7279559b669f47f0a43e8f3464ef" - integrity sha512-4PRT4nh1EImPbt2jASOKHX7PB7I+e4IWNLvkKFDxNhJlfjbYlleYQh285Z/3mPTHSAK/AvdMmw5BNNuYH8ShgQ== + version "3.0.23" + resolved "https://registry.yarnpkg.com/spdx-license-ids/-/spdx-license-ids-3.0.23.tgz#b069e687b1291a32f126893ed76a27a745ee2133" + integrity sha512-CWLcCCH7VLu13TgOH+r8p1O/Znwhqv/dbb6lqWy67G+pT1kHmeD/+V36AVb/vq8QMIQwVShJ6Ssl5FPh0fuSdw== split2@^3.0.0, split2@^3.2.2: version "3.2.2" @@ -8005,9 +7749,9 @@ sprintf-js@~1.0.2: integrity sha512-D9cPgkvLlV3t3IzL0D0YLvGA9Ahk4PcvVwUbN0dSGr1aP0Nrt4AEnTUbuGvquEC0mA64Gqt1fzirlRs5ibXx8g== srcset@^5.0.0: - version "5.0.2" - resolved "https://registry.yarnpkg.com/srcset/-/srcset-5.0.2.tgz#153f05c66b818f787ac51a30ea63c1062f29081a" - integrity sha512-pucR5KmXL7uWI59sXE2nuodomLsfnIQDa5Fck0TooiyxsIx+JYGiFm+wFO7aaDvvl/43ipjUjAb5je7dcAwlzQ== + version "5.0.3" + resolved "https://registry.yarnpkg.com/srcset/-/srcset-5.0.3.tgz#4d174bcff89a4ac995ec3d23b213bf8661bbc8ca" + integrity sha512-AZswtOXIsu0LeHdo6YY7d0r2pCH2Rl1D8ae1utvXUX4GxG3RggsVUAOFX1r8RI4YHFMYb4g89+UBPBv3mNUU2g== stack-utils@^2.0.6: version "2.0.6" @@ -8129,11 +7873,11 @@ strip-ansi@6.0.1, strip-ansi@^6.0.0, strip-ansi@^6.0.1: ansi-regex "^5.0.1" strip-ansi@^7.0.1, strip-ansi@^7.1.0, strip-ansi@^7.1.2: - version "7.1.2" - resolved "https://registry.yarnpkg.com/strip-ansi/-/strip-ansi-7.1.2.tgz#132875abde678c7ea8d691533f2e7e22bb744dba" - integrity sha512-gmBGslpoQJtgnMAvOVqGZpEz9dyoKTCzy2nfz/n8aIFhN/jCE/rCmcxabB6jOOHV+0WNnylOxaxBQPSvcWklhA== + version "7.2.0" + resolved "https://registry.yarnpkg.com/strip-ansi/-/strip-ansi-7.2.0.tgz#d22a269522836a627af8d04b5c3fd2c7fa3e32e3" + integrity sha512-yDPMNjp4WyfYBkHnjIRLfca1i6KMyGCtsVgoKe/z1+6vukgaENdgGBZt+ZmKPc4gavvEZ5OgHfHdrazhgNyG7w== dependencies: - ansi-regex "^6.0.1" + ansi-regex "^6.2.2" strip-bom@^3.0.0: version "3.0.0" @@ -8162,15 +7906,10 @@ strip-json-comments@^3.1.1: resolved "https://registry.yarnpkg.com/strip-json-comments/-/strip-json-comments-3.1.1.tgz#31f1281b3832630434831c310c01cccda8cbe006" integrity sha512-6fPc+R4ihwqP6N/aIv2f1gMH8lOVtWQHoqC4yK6oSDVVocumAsfCqjkXnqiYMhmMwS/mEHLp7Vehlt3ql6lEig== -strnum@^2.1.2: - version "2.1.2" - resolved "https://registry.yarnpkg.com/strnum/-/strnum-2.1.2.tgz#a5e00ba66ab25f9cafa3726b567ce7a49170937a" - integrity sha512-l63NF9y/cLROq/yqKXSLtcMeeyOfnSQlfMSlzFt/K73oIaD8DGaQWd7Z34X9GPiKqP5rbSh84Hl4bOlLcjiSrQ== - -strnum@^2.2.0: - version "2.2.1" - resolved "https://registry.yarnpkg.com/strnum/-/strnum-2.2.1.tgz#d28f896b4ef9985212494ce8bcf7ca304fad8368" - integrity sha512-BwRvNd5/QoAtyW1na1y1LsJGQNvRlkde6Q/ipqqEaivoMdV+B1OMOTVdwR+N/cwVUcIt9PYyHmV8HyexCZSupg== +strnum@^2.2.0, strnum@^2.2.2: + version "2.2.2" + resolved "https://registry.yarnpkg.com/strnum/-/strnum-2.2.2.tgz#f11fd94ab62b536ba2ecc615858f3747c2881b3f" + integrity sha512-DnR90I+jtXNSTXWdwrEy9FakW7UX+qUZg28gj5fk2vxxl7uS/3bpI4fjFYVmdK9etptYBPNkpahuQnEwhwECqA== supports-color@^7, supports-color@^7.0.0, supports-color@^7.1.0: version "7.2.0" @@ -8227,9 +7966,9 @@ text-table@^0.2.0: integrity sha512-N+8UisAXDGk8PFXP4HAzVR9nbfmVJ3zYLAWiTIoqC5v5isinhr+r5uaO8+7r3BMfuNIufIsA7RdpVgacC2cSpw== thingies@^2.5.0: - version "2.5.0" - resolved "https://registry.yarnpkg.com/thingies/-/thingies-2.5.0.tgz#5f7b882c933b85989f8466b528a6247a6881e04f" - integrity sha512-s+2Bwztg6PhWUD7XMfeYm5qliDdSiZm7M7n8KjTkIsm3l/2lgVRc2/Gx/v+ZX8lT4FMA+i8aQvhcWylldc+ZNw== + version "2.6.0" + resolved "https://registry.yarnpkg.com/thingies/-/thingies-2.6.0.tgz#e09b98b9e6f6caf8a759eca8481fea1de974d2b1" + integrity sha512-rMHRjmlFLM1R96UYPvpmnc3LYtdFrT33JIB7L9hetGue1qAPfn1N2LJeEjxUSidu1Iku+haLZXDuEXUHNGO/lg== thread-stream@^3.0.0: version "3.1.0" @@ -8263,17 +8002,17 @@ tinyglobby@^0.2.14, tinyglobby@^0.2.9: fdir "^6.5.0" picomatch "^4.0.3" -tldts-core@^7.0.19: - version "7.0.19" - resolved "https://registry.yarnpkg.com/tldts-core/-/tldts-core-7.0.19.tgz#9dd8a457a09b4e65c8266c029f1847fa78dead20" - integrity sha512-lJX2dEWx0SGH4O6p+7FPwYmJ/bu1JbcGJ8RLaG9b7liIgZ85itUVEPbMtWRVrde/0fnDPEPHW10ZsKW3kVsE9A== +tldts-core@^7.0.27: + version "7.0.27" + resolved "https://registry.yarnpkg.com/tldts-core/-/tldts-core-7.0.27.tgz#4be95bd03b318f2232ea4c1554c4ae9980c77f69" + integrity sha512-YQ7uPjgWUibIK6DW5lrKujGwUKhLevU4hcGbP5O6TcIUb+oTjJYJVWPS4nZsIHrEEEG6myk/oqAJUEQmpZrHsg== tldts@^7.0.5: - version "7.0.19" - resolved "https://registry.yarnpkg.com/tldts/-/tldts-7.0.19.tgz#84cd7a7f04e68ec93b93b106fac038c527b99368" - integrity sha512-8PWx8tvC4jDB39BQw1m4x8y5MH1BcQ5xHeL2n7UVFulMPH/3Q0uiamahFJ3lXA0zO2SUyRXuVVbWSDmstlt9YA== + version "7.0.27" + resolved "https://registry.yarnpkg.com/tldts/-/tldts-7.0.27.tgz#43c3fc6123eb07a3e12ae1868a9f2d1a5889028c" + integrity sha512-I4FZcVFcqCRuT0ph6dCDpPuO4Xgzvh+spkcTr1gK7peIvxWauoloVO0vuy1FQnijT63ss6AsHB6+OIM4aXHbPg== dependencies: - tldts-core "^7.0.19" + tldts-core "^7.0.27" to-regex-range@^5.0.1: version "5.0.1" @@ -8283,9 +8022,9 @@ to-regex-range@^5.0.1: is-number "^7.0.0" tough-cookie@*: - version "6.0.0" - resolved "https://registry.yarnpkg.com/tough-cookie/-/tough-cookie-6.0.0.tgz#11e418b7864a2c0d874702bc8ce0f011261940e5" - integrity sha512-kXuRi1mtaKMrsLUxz3sQYvVl37B0Ns6MzfrtV5DvJceE9bPyspOqk9xxv7XbZWcfLWbFmm997vl83qUWVJA64w== + version "6.0.1" + resolved "https://registry.yarnpkg.com/tough-cookie/-/tough-cookie-6.0.1.tgz#a495f833836609ed983c19bc65639cfbceb54c76" + integrity sha512-LktZQb3IeoUWB9lqR5EWTHgW/VTITCXg4D21M+lvybRVdylLrRMnqaIONLVb5mav8vM19m44HIcGq4qASeu2Qw== dependencies: tldts "^7.0.5" @@ -8533,10 +8272,10 @@ undici-types@~6.21.0: resolved "https://registry.yarnpkg.com/undici-types/-/undici-types-6.21.0.tgz#691d00af3909be93a7faa13be61b3a5b50ef12cb" integrity sha512-iwDZqg0QAGrg9Rav5H4n0M64c3mkR59cJ6wQp+7C4nI0gsmExaedaYLNO44eT4AtBBwjbTiGPMlt2Md0T9H9JQ== -undici-types@~7.16.0: - version "7.16.0" - resolved "https://registry.yarnpkg.com/undici-types/-/undici-types-7.16.0.tgz#ffccdff36aea4884cbfce9a750a0580224f58a46" - integrity sha512-Zz+aZWSj8LE6zoxD+xrjh4VfkIG8Ya6LvYkZqtUQGJPZjYl53ypCaUwWqo7eI0x66KBGeRo+mlBEkMSeSZ38Nw== +undici-types@~7.18.0: + version "7.18.2" + resolved "https://registry.yarnpkg.com/undici-types/-/undici-types-7.18.2.tgz#29357a89e7b7ca4aef3bf0fd3fd0cd73884229e9" + integrity sha512-AsuCzffGHJybSaRrmr5eHr81mwJU3kjw6M+uprWvCXiNeN9SOGwQ3Jn8jb8m3Z6izVgknn1R0FTCEAP2QrLY/w== unicorn-magic@^0.3.0: version "0.3.0" @@ -8573,9 +8312,9 @@ unist-util-visit-parents@^6.0.0: unist-util-is "^6.0.0" unist-util-visit@^5.0.0: - version "5.0.0" - resolved "https://registry.yarnpkg.com/unist-util-visit/-/unist-util-visit-5.0.0.tgz#a7de1f31f72ffd3519ea71814cccf5fd6a9217d6" - integrity sha512-MR04uvD+07cwl/yhVuVWAtw+3GOR/knlL55Nd/wAdblk27GCVt3lqpTivy/tkJcZoNPzTwS1Y+KMojlLDhoTzg== + version "5.1.0" + resolved "https://registry.yarnpkg.com/unist-util-visit/-/unist-util-visit-5.1.0.tgz#9a2a28b0aa76a15e0da70a08a5863a2f060e2468" + integrity sha512-m+vIdyeCOpdr/QeQCu2EzxX/ohgS8KbnPDgFni4dQsfSCtpz8UqDyY5GjRru8PDKuYn7Fq19j1CQ+nJSsGKOzg== dependencies: "@types/unist" "^3.0.0" unist-util-is "^6.0.0" @@ -8591,10 +8330,10 @@ universalify@^2.0.0: resolved "https://registry.yarnpkg.com/universalify/-/universalify-2.0.1.tgz#168efc2180964e6386d061e094df61afe239b18d" integrity sha512-gptHNQghINnc/vTGIk0SOFGFNXw7JVrlRUtConJRlvaw6DuX0wO5Jeko9sWrMBhh+PsYAZ7oXAiOnf/UKogyiw== -update-browserslist-db@^1.1.4: - version "1.1.4" - resolved "https://registry.yarnpkg.com/update-browserslist-db/-/update-browserslist-db-1.1.4.tgz#7802aa2ae91477f255b86e0e46dbc787a206ad4a" - integrity sha512-q0SPT4xyU84saUX+tomz1WLkxUbuaJnR1xWt17M7fJtEJigJeWUNGUqrauFXsHnqev9y9JTRGwk13tFBuKby4A== +update-browserslist-db@^1.2.0: + version "1.2.3" + resolved "https://registry.yarnpkg.com/update-browserslist-db/-/update-browserslist-db-1.2.3.tgz#64d76db58713136acbeb4c49114366cc6cc2e80d" + integrity sha512-Js0m9cx+qOgDxo0eMiFGEueWztz+d4+M3rGlmKPT+T4IS/jP4ylw3Nwpu6cpTTP8R1MAC1kF4VbdLt3ARf209w== dependencies: escalade "^3.2.0" picocolors "^1.1.1" @@ -8742,9 +8481,9 @@ which-module@^2.0.0: integrity sha512-iBdZ57RDvnOR9AGBhML2vFZf7h8vmBjhoaZqODJBFWHVtKkDmKuHai3cx5PgVMrX5YDNp27AofYbAwctSS+vhQ== which-typed-array@^1.1.16, which-typed-array@^1.1.19: - version "1.1.19" - resolved "https://registry.yarnpkg.com/which-typed-array/-/which-typed-array-1.1.19.tgz#df03842e870b6b88e117524a4b364b6fc689f956" - integrity sha512-rEvr90Bck4WZt9HHFC4DJMsjvu7x+r6bImz0/BrbWb7A2djJ8hnZMrWnHo9F8ssv0OMErasDhftrfROTyqSDrw== + version "1.1.20" + resolved "https://registry.yarnpkg.com/which-typed-array/-/which-typed-array-1.1.20.tgz#3fdb7adfafe0ea69157b1509f3a1cd892bd1d122" + integrity sha512-LYfpUkmqwl0h9A2HL09Mms427Q1RZWuOHsukfVcKRq9q95iQxdw0ix1JQrqbcDR9PH1QDwf5Qo8OZb5lksZ8Xg== dependencies: available-typed-arrays "^1.0.7" call-bind "^1.0.8" @@ -8862,9 +8601,9 @@ write-file-atomic@^3.0.0: typedarray-to-buffer "^3.1.5" ws@^8.15.0: - version "8.18.3" - resolved "https://registry.yarnpkg.com/ws/-/ws-8.18.3.tgz#b56b88abffde62791c639170400c93dcb0c95472" - integrity sha512-PEIGCY5tSlUt50cqyMXfCzX+oOPqN0vuGqWzbcJ2xvnkzkq46oOpz7dQaTDBdfICb4N14+GARUDw2XV2N4tvzg== + version "8.20.0" + resolved "https://registry.yarnpkg.com/ws/-/ws-8.20.0.tgz#4cd9532358eba60bc863aad1623dfb045a4d4af8" + integrity sha512-sAt8BhgNbzCtgGbt2OxmpuryO63ZoDk/sqaB/znQm94T4fCEsy/yV+7CdC1kJhOU9lboAEU7R3kquuycDoibVA== xml2js@^0.6.2: version "0.6.2" @@ -8905,9 +8644,9 @@ yallist@^4.0.0: integrity sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A== yaml@^2.5.1, yaml@^2.8.1: - version "2.8.1" - resolved "https://registry.yarnpkg.com/yaml/-/yaml-2.8.1.tgz#1870aa02b631f7e8328b93f8bc574fac5d6c4d79" - integrity sha512-lcYcMxX2PO9XMGvAJkJ3OsNMw+/7FKes7/hgerGUYWIoWu5j/+YQqcZr5JnPZWzOsEBgMbSbiSTn/dv/69Mkpw== + version "2.8.3" + resolved "https://registry.yarnpkg.com/yaml/-/yaml-2.8.3.tgz#a0d6bd2efb3dd03c59370223701834e60409bd7d" + integrity sha512-AvbaCLOO2Otw/lW5bmh9d/WEdcDFdQp2Z2ZUH3pX9U2ihyUY0nvLv7J6TrWowklRGPYbB/IuIMfYgxaCPg5Bpg== yargs-parser@^18.1.2: version "18.1.3" @@ -9001,9 +8740,9 @@ yoga-wasm-web@~0.3.3: integrity sha512-N+d4UJSJbt/R3wqY7Coqs5pcV0aUj2j9IaQ3rNj9bVCLld8tTGKRa2USARjnvZJWVx1NDmQev8EknoczaOQDOA== zod@^4.1.12: - version "4.1.13" - resolved "https://registry.yarnpkg.com/zod/-/zod-4.1.13.tgz#93699a8afe937ba96badbb0ce8be6033c0a4b6b1" - integrity sha512-AvvthqfqrAhNH9dnfmrfKzX5upOdjUVJYFqNSlkmGf64gRaTzlPwz99IHYnVs28qYAybvAlBV+H7pn0saFY4Ig== + version "4.3.6" + resolved "https://registry.yarnpkg.com/zod/-/zod-4.3.6.tgz#89c56e0aa7d2b05107d894412227087885ab112a" + integrity sha512-rftlrkhHZOcjDwkGlnUtZZkvaPHCsDATp4pGpuOOMDaTdDDXF91wuVDJoWoPsKX/3YPQ5fHuF3STjcYyKr+Qhg== zwitch@^2.0.4: version "2.0.4" From 4129eb010c27c4a254e7192ce6ad26241f10775e Mon Sep 17 00:00:00 2001 From: "b.tran" Date: Fri, 27 Mar 2026 13:41:12 -0400 Subject: [PATCH 7/9] fix: update schema --- schemas/package-bundle-uninstall.json | 47 +++++++++++++++++++++++++++ 1 file changed, 47 insertions(+) create mode 100644 schemas/package-bundle-uninstall.json diff --git a/schemas/package-bundle-uninstall.json b/schemas/package-bundle-uninstall.json new file mode 100644 index 00000000..dda0599c --- /dev/null +++ b/schemas/package-bundle-uninstall.json @@ -0,0 +1,47 @@ +{ + "$schema": "http://json-schema.org/draft-07/schema#", + "$ref": "#/definitions/BundleUninstallResult", + "definitions": { + "BundleUninstallResult": { + "$ref": "#/definitions/BundleSObjects.PkgBundleVerUninstallReqResult" + }, + "BundleSObjects.PkgBundleVerUninstallReqResult": { + "type": "object", + "additionalProperties": false, + "properties": { + "Id": { + "type": "string" + }, + "UninstallStatus": { + "$ref": "#/definitions/BundleSObjects.PkgBundleVersionUninstallReqStatus" + }, + "CreatedDate": { + "type": "string" + }, + "CreatedById": { + "type": "string" + }, + "Error": { + "type": "array", + "items": { + "type": "string" + } + }, + "PackageBundleVersionId": { + "type": "string" + }, + "InstalledPkgBundleVersionId": { + "type": "string" + }, + "ValidationError": { + "type": "string" + } + }, + "required": ["CreatedById", "CreatedDate", "Id", "PackageBundleVersionId", "UninstallStatus"] + }, + "BundleSObjects.PkgBundleVersionUninstallReqStatus": { + "type": "string", + "enum": ["Queued", "InProgress", "Success", "Error"] + } + } +} From f17fa7d94184bc647a9829287f0cd55524c08469 Mon Sep 17 00:00:00 2001 From: "b.tran" Date: Fri, 27 Mar 2026 13:45:28 -0400 Subject: [PATCH 8/9] fix: update schema --- schemas/package-bundle-install-list.json | 63 ------------------------ 1 file changed, 63 deletions(-) delete mode 100644 schemas/package-bundle-install-list.json diff --git a/schemas/package-bundle-install-list.json b/schemas/package-bundle-install-list.json deleted file mode 100644 index ebe2980c..00000000 --- a/schemas/package-bundle-install-list.json +++ /dev/null @@ -1,63 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema#", - "$ref": "#/definitions/PackageBundleInstallRequestResults", - "definitions": { - "PackageBundleInstallRequestResults": { - "type": "array", - "items": { - "$ref": "#/definitions/BundleSObjects.PkgBundleVersionInstallReqResult" - } - }, - "BundleSObjects.PkgBundleVersionInstallReqResult": { - "type": "object", - "additionalProperties": false, - "properties": { - "Id": { - "type": "string" - }, - "InstallStatus": { - "$ref": "#/definitions/BundleSObjects.PkgBundleVersionInstallReqStatus" - }, - "ValidationError": { - "type": "string" - }, - "CreatedDate": { - "type": "string" - }, - "CreatedById": { - "type": "string" - }, - "Error": { - "type": "array", - "items": { - "type": "string" - } - }, - "PackageBundleVersionId": { - "type": "string" - }, - "DevelopmentOrganization": { - "type": "string" - } - }, - "required": [ - "CreatedById", - "CreatedDate", - "DevelopmentOrganization", - "Id", - "InstallStatus", - "PackageBundleVersionId", - "ValidationError" - ] - }, - "BundleSObjects.PkgBundleVersionInstallReqStatus": { - "type": "string", - "enum": [ - "Queued", - "InProgress", - "Success", - "Error" - ] - } - } -} \ No newline at end of file From f7ef59c7bcdbabbff64caca07faeb8634d12a325 Mon Sep 17 00:00:00 2001 From: "b.tran" Date: Fri, 27 Mar 2026 13:50:37 -0400 Subject: [PATCH 9/9] fix: tf fix --- src/commands/package/install.ts | 12 ++++++++++-- test/commands/package/install.test.ts | 22 +++------------------- 2 files changed, 13 insertions(+), 21 deletions(-) diff --git a/src/commands/package/install.ts b/src/commands/package/install.ts index 4badddc3..6c30d3ce 100644 --- a/src/commands/package/install.ts +++ b/src/commands/package/install.ts @@ -21,7 +21,7 @@ import { requiredOrgFlagWithDeprecations, SfCommand, } from '@salesforce/sf-plugins-core'; -import { Connection, Lifecycle, Messages, SfError } from '@salesforce/core'; +import { Connection, Lifecycle, Messages, SfError, SfProject } from '@salesforce/core'; import { Duration } from '@salesforce/kit'; import { PackageEvents, @@ -135,9 +135,17 @@ export class Install extends SfCommand { throw messages.createError('apiVersionTooLow'); } + let packageId = flags.package; + try { + const project = SfProject.getInstance(); + packageId = project.getPackageIdFromAlias(flags.package) ?? flags.package; + } catch { + // not in a project directory; use the value as-is + } + this.subscriberPackageVersion = new SubscriberPackageVersion({ connection: this.connection, - aliasOrId: flags.package, + aliasOrId: packageId, password: flags['installation-key'], }); diff --git a/test/commands/package/install.test.ts b/test/commands/package/install.test.ts index 4a299024..c69f72c6 100644 --- a/test/commands/package/install.test.ts +++ b/test/commands/package/install.test.ts @@ -14,7 +14,7 @@ * limitations under the License. */ import { EOL } from 'node:os'; -import { Connection, Lifecycle, SfProject, SfError, SfProjectJson } from '@salesforce/core'; +import { Connection, Lifecycle, SfProject, SfError } from '@salesforce/core'; import { MockTestOrgData, TestContext } from '@salesforce/core/testSetup'; import { Config } from '@oclif/core'; import { expect } from 'chai'; @@ -283,27 +283,11 @@ describe('package:install', () => { } }); - // TODO: It seems that while linking @salesforce/packaging into the plugin - // we cannot stub the library calls of `SfProject.getInstance` e.g. "SfProject, 'getInstance'" - // once the library has been published, the stubs resume to work and this test will pass it('should print SUCCESS status correctly for package alias', async () => { - // Stubs SfProject.getInstance, SfProject.getSfProjectJson, and SfProjectJson.getContents - // in a way that makes TS happy... all to test package aliases. - const getContentsStub = $$.SANDBOX.stub(SfProjectJson.prototype, 'getContents').returns({ - packageAliases: { ['my_package_alias']: myPackageVersion04t }, - packageDirectories: [], - }); - // @ts-expect-error stubbing only 1 method - const getSfProjectJsonStub = $$.SANDBOX.stub(SfProject.prototype, 'getSfProjectJson').callsFake(() => ({ - getContents: getContentsStub, - })); - const getPackageIdFromAliasStub = $$.SANDBOX.stub(SfProject.prototype, 'getPackageIdFromAlias').returns( - myPackageVersion04t - ); + $$.SANDBOX.stub(SfProject.prototype, 'getPackageIdFromAlias').returns(myPackageVersion04t); // @ts-expect-error stubbing only a subset of methods $$.SANDBOX.stub(SfProject, 'getInstance').callsFake(() => ({ - getSfProjectJson: getSfProjectJsonStub, - getPackageIdFromAlias: getPackageIdFromAliasStub, + getPackageIdFromAlias: $$.SANDBOX.stub().returns(myPackageVersion04t), })); const request = Object.assign({}, pkgInstallRequest, { Status: 'SUCCESS' });