diff --git a/messages/list.md b/messages/list.md index 7378a289..2b154f10 100644 --- a/messages/list.md +++ b/messages/list.md @@ -46,7 +46,7 @@ No active scratch orgs found. Specify --all to see all scratch orgs. # deleteOrgs -You have %s expired or deleted local scratch org authorizations. To remove authorizations for inactive orgs, run "org list --clean". +You have %s expired or deleted local scratch org authorizations. To remove authorizations for inactive orgs, run "sf org list --clean".%s # noOrgsFound diff --git a/src/commands/org/list.ts b/src/commands/org/list.ts index dd5a305b..d18da166 100644 --- a/src/commands/org/list.ts +++ b/src/commands/org/list.ts @@ -5,6 +5,7 @@ * For full license text, see LICENSE.txt file in the repo root or https://opensource.org/licenses/BSD-3-Clause */ +import { EOL } from 'node:os'; import { Flags, loglevel, SfCommand } from '@salesforce/sf-plugins-core'; import { AuthInfo, ConfigAggregator, ConfigInfo, Connection, Org, SfError, Messages, Logger } from '@salesforce/core'; import { Interfaces } from '@oclif/core'; @@ -87,8 +88,8 @@ export class OrgListCommand extends SfCommand { await this.cleanScratchOrgs(groupedSortedOrgs.expiredScratchOrgs, !flags['no-prompt']); } - if (groupedSortedOrgs.expiredScratchOrgs.length > 10 && !flags.clean) { - this.warn(messages.getMessage('deleteOrgs', [groupedSortedOrgs.expiredScratchOrgs.length])); + if (groupedSortedOrgs.expiredScratchOrgs.length >= 1 && !flags.clean) { + this.warn(messages.getMessage('deleteOrgs', [groupedSortedOrgs.expiredScratchOrgs.length, EOL])); } const result = {