@salesforce/plugin-org 4.8.2 → 5.0.1

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/README.md CHANGED
@@ -76,7 +76,7 @@ To use your plugin, run using the local `./bin/dev` or `./bin/dev.cmd` file.
76
76
 
77
77
  ```bash
78
78
  # Run using local run file.
79
- ./bin/dev force:org:list
79
+ ./bin/dev.js org list
80
80
  ```
81
81
 
82
82
  There should be no differences when running via the Salesforce CLI or using the local run file. However, it can be
@@ -229,7 +229,7 @@ FLAG DESCRIPTIONS
229
229
  sandbox.
230
230
  ```
231
231
 
232
- _See code: [src/commands/org/create/sandbox.ts](https://github.com/salesforcecli/plugin-org/blob/4.8.2/src/commands/org/create/sandbox.ts)_
232
+ _See code: [src/commands/org/create/sandbox.ts](https://github.com/salesforcecli/plugin-org/blob/5.0.1/src/commands/org/create/sandbox.ts)_
233
233
 
234
234
  ## `sf org create scratch`
235
235
 
@@ -383,7 +383,7 @@ FLAG DESCRIPTIONS
383
383
  Omit this flag to have Salesforce generate a unique username for your org.
384
384
  ```
385
385
 
386
- _See code: [src/commands/org/create/scratch.ts](https://github.com/salesforcecli/plugin-org/blob/4.8.2/src/commands/org/create/scratch.ts)_
386
+ _See code: [src/commands/org/create/scratch.ts](https://github.com/salesforcecli/plugin-org/blob/5.0.1/src/commands/org/create/scratch.ts)_
387
387
 
388
388
  ## `sf org delete sandbox`
389
389
 
@@ -429,7 +429,7 @@ EXAMPLES
429
429
  $ sf org delete sandbox --target-org my-sandbox --no-prompt
430
430
  ```
431
431
 
432
- _See code: [src/commands/org/delete/sandbox.ts](https://github.com/salesforcecli/plugin-org/blob/4.8.2/src/commands/org/delete/sandbox.ts)_
432
+ _See code: [src/commands/org/delete/sandbox.ts](https://github.com/salesforcecli/plugin-org/blob/5.0.1/src/commands/org/delete/sandbox.ts)_
433
433
 
434
434
  ## `sf org delete scratch`
435
435
 
@@ -473,7 +473,7 @@ EXAMPLES
473
473
  $ sf org delete scratch --target-org my-scratch-org --no-prompt
474
474
  ```
475
475
 
476
- _See code: [src/commands/org/delete/scratch.ts](https://github.com/salesforcecli/plugin-org/blob/4.8.2/src/commands/org/delete/scratch.ts)_
476
+ _See code: [src/commands/org/delete/scratch.ts](https://github.com/salesforcecli/plugin-org/blob/5.0.1/src/commands/org/delete/scratch.ts)_
477
477
 
478
478
  ## `sf org disable tracking`
479
479
 
@@ -512,7 +512,7 @@ EXAMPLES
512
512
  $ sf org disable tracking
513
513
  ```
514
514
 
515
- _See code: [src/commands/org/disable/tracking.ts](https://github.com/salesforcecli/plugin-org/blob/4.8.2/src/commands/org/disable/tracking.ts)_
515
+ _See code: [src/commands/org/disable/tracking.ts](https://github.com/salesforcecli/plugin-org/blob/5.0.1/src/commands/org/disable/tracking.ts)_
516
516
 
517
517
  ## `sf org display`
518
518
 
@@ -557,7 +557,7 @@ EXAMPLES
557
557
  $ sf org display --target-org TestOrg1 --verbose
558
558
  ```
559
559
 
560
- _See code: [src/commands/org/display.ts](https://github.com/salesforcecli/plugin-org/blob/4.8.2/src/commands/org/display.ts)_
560
+ _See code: [src/commands/org/display.ts](https://github.com/salesforcecli/plugin-org/blob/5.0.1/src/commands/org/display.ts)_
561
561
 
562
562
  ## `sf org enable tracking`
563
563
 
@@ -599,7 +599,7 @@ EXAMPLES
599
599
  $ sf org enable tracking
600
600
  ```
601
601
 
602
- _See code: [src/commands/org/enable/tracking.ts](https://github.com/salesforcecli/plugin-org/blob/4.8.2/src/commands/org/enable/tracking.ts)_
602
+ _See code: [src/commands/org/enable/tracking.ts](https://github.com/salesforcecli/plugin-org/blob/5.0.1/src/commands/org/enable/tracking.ts)_
603
603
 
604
604
  ## `sf org list`
605
605
 
@@ -638,7 +638,7 @@ EXAMPLES
638
638
  $ sf org list --clean
639
639
  ```
640
640
 
641
- _See code: [src/commands/org/list.ts](https://github.com/salesforcecli/plugin-org/blob/4.8.2/src/commands/org/list.ts)_
641
+ _See code: [src/commands/org/list.ts](https://github.com/salesforcecli/plugin-org/blob/5.0.1/src/commands/org/list.ts)_
642
642
 
643
643
  ## `sf org list metadata`
644
644
 
@@ -705,7 +705,7 @@ FLAG DESCRIPTIONS
705
705
  Examples of metadata types that use folders are Dashboard, Document, EmailTemplate, and Report.
706
706
  ```
707
707
 
708
- _See code: [src/commands/org/list/metadata.ts](https://github.com/salesforcecli/plugin-org/blob/4.8.2/src/commands/org/list/metadata.ts)_
708
+ _See code: [src/commands/org/list/metadata.ts](https://github.com/salesforcecli/plugin-org/blob/5.0.1/src/commands/org/list/metadata.ts)_
709
709
 
710
710
  ## `sf org list metadata-types`
711
711
 
@@ -760,7 +760,7 @@ FLAG DESCRIPTIONS
760
760
  Override the api version used for api requests made by this command
761
761
  ```
762
762
 
763
- _See code: [src/commands/org/list/metadata-types.ts](https://github.com/salesforcecli/plugin-org/blob/4.8.2/src/commands/org/list/metadata-types.ts)_
763
+ _See code: [src/commands/org/list/metadata-types.ts](https://github.com/salesforcecli/plugin-org/blob/5.0.1/src/commands/org/list/metadata-types.ts)_
764
764
 
765
765
  ## `sf org open`
766
766
 
@@ -836,7 +836,7 @@ EXAMPLES
836
836
  $ sf org open --source-file force-app/main/default/bots/Coral_Cloud_Agent/Coral_Cloud_Agent.bot-meta.xml
837
837
  ```
838
838
 
839
- _See code: [src/commands/org/open.ts](https://github.com/salesforcecli/plugin-org/blob/4.8.2/src/commands/org/open.ts)_
839
+ _See code: [src/commands/org/open.ts](https://github.com/salesforcecli/plugin-org/blob/5.0.1/src/commands/org/open.ts)_
840
840
 
841
841
  ## `sf org refresh sandbox`
842
842
 
@@ -913,7 +913,7 @@ FLAG DESCRIPTIONS
913
913
  By default, a sandbox auto-activates after a refresh. Use this flag to control sandbox activation manually.
914
914
  ```
915
915
 
916
- _See code: [src/commands/org/refresh/sandbox.ts](https://github.com/salesforcecli/plugin-org/blob/4.8.2/src/commands/org/refresh/sandbox.ts)_
916
+ _See code: [src/commands/org/refresh/sandbox.ts](https://github.com/salesforcecli/plugin-org/blob/5.0.1/src/commands/org/refresh/sandbox.ts)_
917
917
 
918
918
  ## `sf org resume sandbox`
919
919
 
@@ -976,7 +976,7 @@ FLAG DESCRIPTIONS
976
976
  returns the job ID. To resume checking the sandbox creation, rerun this command.
977
977
  ```
978
978
 
979
- _See code: [src/commands/org/resume/sandbox.ts](https://github.com/salesforcecli/plugin-org/blob/4.8.2/src/commands/org/resume/sandbox.ts)_
979
+ _See code: [src/commands/org/resume/sandbox.ts](https://github.com/salesforcecli/plugin-org/blob/5.0.1/src/commands/org/resume/sandbox.ts)_
980
980
 
981
981
  ## `sf org resume scratch`
982
982
 
@@ -1023,6 +1023,6 @@ FLAG DESCRIPTIONS
1023
1023
  The job ID is valid for 24 hours after you start the scratch org creation.
1024
1024
  ```
1025
1025
 
1026
- _See code: [src/commands/org/resume/scratch.ts](https://github.com/salesforcecli/plugin-org/blob/4.8.2/src/commands/org/resume/scratch.ts)_
1026
+ _See code: [src/commands/org/resume/scratch.ts](https://github.com/salesforcecli/plugin-org/blob/5.0.1/src/commands/org/resume/scratch.ts)_
1027
1027
 
1028
1028
  <!-- commandsstop -->
@@ -7,7 +7,7 @@
7
7
  import { Flags } from '@oclif/core';
8
8
  import { ConfigAggregator, StateAggregator, Messages, SfError } from '@salesforce/core';
9
9
  Messages.importMessagesDirectoryFromMetaUrl(import.meta.url);
10
- const messages = Messages.loadMessages('@salesforce/plugin-org', 'delete');
10
+ const messages = Messages.loadMessages('@salesforce/plugin-org', 'delete_scratch');
11
11
  const resolveUsername = async (usernameOrAlias) => {
12
12
  const stateAggregator = await StateAggregator.getInstance();
13
13
  // we have a value, but don't know if it's a username or an alias
@@ -18,7 +18,7 @@ const resolveUsername = async (usernameOrAlias) => {
18
18
  const defaultUsernameOrAlias = configAggregator.getPropertyValue('target-org');
19
19
  if (defaultUsernameOrAlias)
20
20
  return stateAggregator.aliases.resolveUsername(defaultUsernameOrAlias);
21
- throw new SfError(messages.getMessage('missingUsername'), 'MissingUsernameError');
21
+ throw new SfError(messages.getMessage('error.missingUsername'), 'MissingUsernameError');
22
22
  };
23
23
  /**
24
24
  * Almost like the use case for the normal optional org flag,
@@ -1 +1 @@
1
- {"version":3,"file":"flags.js","sourceRoot":"","sources":["../../src/shared/flags.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,EAAE,KAAK,EAAE,MAAM,aAAa,CAAC;AACpC,OAAO,EAAE,gBAAgB,EAAE,eAAe,EAAE,QAAQ,EAAE,OAAO,EAAE,MAAM,kBAAkB,CAAC;AAExF,QAAQ,CAAC,kCAAkC,CAAC,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;AAC7D,MAAM,QAAQ,GAAG,QAAQ,CAAC,YAAY,CAAC,wBAAwB,EAAE,QAAQ,CAAC,CAAC;AAE3E,MAAM,eAAe,GAAG,KAAK,EAAE,eAAwB,EAAmB,EAAE;IAC1E,MAAM,eAAe,GAAG,MAAM,eAAe,CAAC,WAAW,EAAE,CAAC;IAC5D,iEAAiE;IACjE,IAAI,eAAe;QAAE,OAAO,eAAe,CAAC,OAAO,CAAC,eAAe,CAAC,eAAe,CAAC,CAAC;IACrF,6EAA6E;IAC7E,MAAM,gBAAgB,GAAG,MAAM,gBAAgB,CAAC,MAAM,EAAE,CAAC;IACzD,MAAM,sBAAsB,GAAG,gBAAgB,CAAC,gBAAgB,CAAC,YAAY,CAAuB,CAAC;IACrG,IAAI,sBAAsB;QAAE,OAAO,eAAe,CAAC,OAAO,CAAC,eAAe,CAAC,sBAAsB,CAAC,CAAC;IACnG,MAAM,IAAI,OAAO,CAAC,QAAQ,CAAC,UAAU,CAAC,iBAAiB,CAAC,EAAE,sBAAsB,CAAC,CAAC;AACpF,CAAC,CAAC;AAEF;;;;;GAKG;AACH,MAAM,CAAC,MAAM,qBAAqB,GAAG,KAAK,CAAC,MAAM,CAAC;IAChD,IAAI,EAAE,GAAG;IACT,QAAQ,EAAE,IAAI;IACd,gBAAgB,EAAE,IAAI;IACtB,OAAO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ACH,MAAM,CAAC,MAAM,qBAAqB,GAAG,KAAK,CAAC,MAAM,CAAC;IAChD,IAAI,EAAE,GAAG;IACT,QAAQ,EAAE,IAAI;IACd,gBAAgB,EAAE,IAAI;IACtB,OAAO,EAAE,CAAC,gBAAgB,EAAE,GAAG,CAAC;IAChC,KAAK,EAAE,KAAK,EAAE,KAAyB,EAAE,EAAE,CAAC,eAAe,CAAC,KAAK,CAAC;IAClE,OAAO,EAAE,KAAK,IAAI,EAAE,CAAC,eAAe,EAAE;IACtC,WAAW,EAAE,KAAK,IAAI,EAAE,CAAC,eAAe,EAAE;CAC3C,CAAC,CAAC"}
@@ -50,3 +50,7 @@ The org with username: %s is not known by the CLI to be a sandbox
50
50
 
51
51
  Re-authenticate the sandbox with the CLI and try again.
52
52
  Ensure the CLI has authenticated with the sandbox's production org.
53
+
54
+ # error.missingUsername
55
+
56
+ Unable to determine the username of the org to delete. Specify the username with the --target-org | -o flag.
@@ -40,3 +40,7 @@ Successfully marked scratch org %s for deletion.
40
40
  # success.Idempotent
41
41
 
42
42
  Successfully deleted scratch org %s.
43
+
44
+ # error.missingUsername
45
+
46
+ Unable to determine the username of the org to delete. Specify the username with the --target-org | -o flag.
@@ -385,315 +385,6 @@
385
385
  "open:org"
386
386
  ]
387
387
  },
388
- "force:org:create": {
389
- "aliases": [],
390
- "args": {},
391
- "deprecationOptions": {
392
- "message": "The force:org:create command is deprecated and will be removed on November 6, 2024. Use \"org create scratch\" or \"org create sandbox\" instead."
393
- },
394
- "description": "Creates a scratch org or a sandbox org using the values specified in a configuration file or key=value pairs that you specify on the command line. Values specified on the command line override values in the configuration file. Specify a configuration file or provide key=value pairs while creating a scratch org or a sandbox. When creating scratch orgs, —targetdevhubusername (-v) must be a Dev Hub org. When creating sandboxes, the --targetusername (-u) must be a production org with sandbox licenses. The —type (-t) is required if creating a sandbox.",
395
- "examples": [
396
- "$ <%= config.bin %> <%= command.id %> -f config/enterprise-scratch-def.json -a MyScratchOrg",
397
- "$ <%= config.bin %> <%= command.id %> edition=Developer -a MyScratchOrg -s -v devHub",
398
- "$ <%= config.bin %> <%= command.id %> -f config/enterprise-scratch-def.json -a ScratchOrgWithOverrides username=testuser1@mycompany.org",
399
- "$ <%= config.bin %> <%= command.id %> -t sandbox -f config/dev-sandbox-def.json -a MyDevSandbox -u prodOrg"
400
- ],
401
- "flags": {
402
- "json": {
403
- "description": "Format output as json.",
404
- "helpGroup": "GLOBAL",
405
- "name": "json",
406
- "allowNo": false,
407
- "type": "boolean"
408
- },
409
- "flags-dir": {
410
- "helpGroup": "GLOBAL",
411
- "name": "flags-dir",
412
- "summary": "Import flag values from a directory.",
413
- "hasDynamicHelp": false,
414
- "multiple": false,
415
- "type": "option"
416
- },
417
- "target-org": {
418
- "aliases": [
419
- "targetusername",
420
- "u"
421
- ],
422
- "char": "o",
423
- "deprecateAliases": true,
424
- "name": "target-org",
425
- "noCacheDefault": true,
426
- "summary": "Username or alias of the production org that contains the sandbox license.",
427
- "hasDynamicHelp": true,
428
- "multiple": false,
429
- "type": "option"
430
- },
431
- "target-dev-hub": {
432
- "aliases": [
433
- "targetdevhubusername"
434
- ],
435
- "char": "v",
436
- "deprecateAliases": true,
437
- "name": "target-dev-hub",
438
- "noCacheDefault": true,
439
- "required": false,
440
- "summary": "Username or alias of the Dev Hub org.",
441
- "hasDynamicHelp": true,
442
- "multiple": false,
443
- "type": "option"
444
- },
445
- "api-version": {
446
- "aliases": [
447
- "apiversion"
448
- ],
449
- "deprecateAliases": true,
450
- "description": "Override the api version used for api requests made by this command",
451
- "name": "api-version",
452
- "hasDynamicHelp": false,
453
- "multiple": false,
454
- "type": "option"
455
- },
456
- "loglevel": {
457
- "deprecated": {
458
- "message": "The loglevel flag is no longer in use on this command. You may use it without error, but it will be ignored.\nSet the log level using the `SFDX_LOG_LEVEL` environment variable."
459
- },
460
- "hidden": true,
461
- "name": "loglevel",
462
- "hasDynamicHelp": false,
463
- "multiple": false,
464
- "type": "option"
465
- },
466
- "type": {
467
- "char": "t",
468
- "name": "type",
469
- "summary": "Type of org to create.",
470
- "default": "scratch",
471
- "hasDynamicHelp": false,
472
- "multiple": false,
473
- "options": [
474
- "scratch",
475
- "sandbox"
476
- ],
477
- "type": "option"
478
- },
479
- "definitionfile": {
480
- "char": "f",
481
- "name": "definitionfile",
482
- "summary": "Path to an org definition file.",
483
- "hasDynamicHelp": false,
484
- "multiple": false,
485
- "type": "option"
486
- },
487
- "nonamespace": {
488
- "char": "n",
489
- "name": "nonamespace",
490
- "summary": "Create the scratch org with no namespace.",
491
- "allowNo": false,
492
- "type": "boolean"
493
- },
494
- "noancestors": {
495
- "char": "c",
496
- "name": "noancestors",
497
- "summary": "Do not include second-generation package ancestors in the scratch org.",
498
- "allowNo": false,
499
- "type": "boolean"
500
- },
501
- "clientid": {
502
- "char": "i",
503
- "name": "clientid",
504
- "summary": "Connected app consumer key; not supported for sandbox org creation.",
505
- "hasDynamicHelp": false,
506
- "multiple": false,
507
- "type": "option"
508
- },
509
- "setdefaultusername": {
510
- "char": "s",
511
- "name": "setdefaultusername",
512
- "summary": "Set the created org as the default username.",
513
- "allowNo": false,
514
- "type": "boolean"
515
- },
516
- "setalias": {
517
- "char": "a",
518
- "name": "setalias",
519
- "summary": "Alias for the created org.",
520
- "hasDynamicHelp": false,
521
- "multiple": false,
522
- "type": "option"
523
- },
524
- "wait": {
525
- "char": "w",
526
- "name": "wait",
527
- "summary": "Streaming client socket timeout (in minutes).",
528
- "default": "6 minutes",
529
- "hasDynamicHelp": true,
530
- "multiple": false,
531
- "type": "option"
532
- },
533
- "durationdays": {
534
- "char": "d",
535
- "name": "durationdays",
536
- "summary": "Duration of the scratch org (in days) (default:7, min:1, max:30).",
537
- "default": 7,
538
- "hasDynamicHelp": false,
539
- "multiple": false,
540
- "type": "option"
541
- },
542
- "retry": {
543
- "hidden": true,
544
- "name": "retry",
545
- "summary": "Number of scratch org auth retries after scratch org is successfully signed up.",
546
- "default": 0,
547
- "hasDynamicHelp": false,
548
- "multiple": false,
549
- "type": "option"
550
- }
551
- },
552
- "hasDynamicHelp": true,
553
- "hidden": true,
554
- "hiddenAliases": [],
555
- "id": "force:org:create",
556
- "pluginAlias": "@salesforce/plugin-org",
557
- "pluginName": "@salesforce/plugin-org",
558
- "pluginType": "core",
559
- "state": "deprecated",
560
- "strict": false,
561
- "summary": "Create a scratch org or sandbox.",
562
- "enableJsonFlag": true,
563
- "isESM": true,
564
- "relativePath": [
565
- "lib",
566
- "commands",
567
- "force",
568
- "org",
569
- "create.js"
570
- ],
571
- "aliasPermutations": [],
572
- "permutations": [
573
- "force:org:create",
574
- "org:force:create",
575
- "org:create:force",
576
- "force:create:org",
577
- "create:force:org",
578
- "create:org:force"
579
- ]
580
- },
581
- "force:org:delete": {
582
- "aliases": [],
583
- "args": {},
584
- "deprecationOptions": {
585
- "message": "The force:org:delete command is deprecated and will be removed on November 6, 2024. Use \"org delete scratch\" or \"org delete sandbox\" instead."
586
- },
587
- "description": "Salesforce CLI marks the org for deletion in either the Dev Hub org (for scratch orgs) or production org (for sandboxes) and then deletes all local references to the org from your computer.\n\nTo mark the org for deletion without being prompted to confirm, specify --noprompt.",
588
- "examples": [
589
- "$ <%= config.bin %> <%= command.id %> -u me@my.org",
590
- "$ <%= config.bin %> <%= command.id %> -u MyOrgAlias -p"
591
- ],
592
- "flags": {
593
- "json": {
594
- "description": "Format output as json.",
595
- "helpGroup": "GLOBAL",
596
- "name": "json",
597
- "allowNo": false,
598
- "type": "boolean"
599
- },
600
- "flags-dir": {
601
- "helpGroup": "GLOBAL",
602
- "name": "flags-dir",
603
- "summary": "Import flag values from a directory.",
604
- "hasDynamicHelp": false,
605
- "multiple": false,
606
- "type": "option"
607
- },
608
- "target-org": {
609
- "aliases": [
610
- "targetusername",
611
- "u"
612
- ],
613
- "char": "o",
614
- "deprecateAliases": true,
615
- "name": "target-org",
616
- "required": true,
617
- "summary": "Username or alias of the target org.",
618
- "hasDynamicHelp": true,
619
- "multiple": false,
620
- "type": "option"
621
- },
622
- "targetdevhubusername": {
623
- "char": "v",
624
- "deprecated": {
625
- "version": "58.0",
626
- "message": "The targetdevhubusername flag exists only for backwards compatibility. It is not necessary and has no effect."
627
- },
628
- "hidden": true,
629
- "name": "targetdevhubusername",
630
- "summary": "The targetdevhubusername flag exists only for backwards compatibility. It is not necessary and has no effect.",
631
- "hasDynamicHelp": false,
632
- "multiple": false,
633
- "type": "option"
634
- },
635
- "api-version": {
636
- "aliases": [
637
- "apiversion"
638
- ],
639
- "deprecateAliases": true,
640
- "description": "Override the api version used for api requests made by this command",
641
- "name": "api-version",
642
- "hasDynamicHelp": false,
643
- "multiple": false,
644
- "type": "option"
645
- },
646
- "no-prompt": {
647
- "aliases": [
648
- "noprompt"
649
- ],
650
- "char": "p",
651
- "deprecateAliases": true,
652
- "name": "no-prompt",
653
- "summary": "No prompt to confirm deletion.",
654
- "allowNo": false,
655
- "type": "boolean"
656
- },
657
- "loglevel": {
658
- "deprecated": {
659
- "message": "The loglevel flag is no longer in use on this command. You may use it without error, but it will be ignored.\nSet the log level using the `SFDX_LOG_LEVEL` environment variable."
660
- },
661
- "hidden": true,
662
- "name": "loglevel",
663
- "hasDynamicHelp": false,
664
- "multiple": false,
665
- "type": "option"
666
- }
667
- },
668
- "hasDynamicHelp": true,
669
- "hidden": true,
670
- "hiddenAliases": [],
671
- "id": "force:org:delete",
672
- "pluginAlias": "@salesforce/plugin-org",
673
- "pluginName": "@salesforce/plugin-org",
674
- "pluginType": "core",
675
- "state": "deprecated",
676
- "strict": true,
677
- "summary": "Delete a scratch or sandbox org.",
678
- "enableJsonFlag": true,
679
- "isESM": true,
680
- "relativePath": [
681
- "lib",
682
- "commands",
683
- "force",
684
- "org",
685
- "delete.js"
686
- ],
687
- "aliasPermutations": [],
688
- "permutations": [
689
- "force:org:delete",
690
- "org:force:delete",
691
- "org:delete:force",
692
- "force:delete:org",
693
- "delete:force:org",
694
- "delete:org:force"
695
- ]
696
- },
697
388
  "org:create:sandbox": {
698
389
  "aliases": [
699
390
  "env:create:sandbox"
@@ -1990,5 +1681,5 @@
1990
1681
  ]
1991
1682
  }
1992
1683
  },
1993
- "version": "4.8.2"
1684
+ "version": "5.0.1"
1994
1685
  }
package/package.json CHANGED
@@ -1,12 +1,12 @@
1
1
  {
2
2
  "name": "@salesforce/plugin-org",
3
3
  "description": "Commands to interact with Salesforce orgs",
4
- "version": "4.8.2",
4
+ "version": "5.0.1",
5
5
  "author": "Salesforce",
6
6
  "bugs": "https://github.com/forcedotcom/cli/issues",
7
7
  "dependencies": {
8
8
  "@oclif/core": "^4.0.29",
9
- "@oclif/multi-stage-output": "^0.7.7",
9
+ "@oclif/multi-stage-output": "^0.7.8",
10
10
  "@salesforce/core": "^8.6.3",
11
11
  "@salesforce/kit": "^3.2.3",
12
12
  "@salesforce/sf-plugins-core": "^12.0.9",
@@ -25,7 +25,7 @@
25
25
  "@salesforce/ts-sinon": "^1.4.27",
26
26
  "eslint-plugin-sf-plugin": "^1.20.8",
27
27
  "moment": "^2.30.1",
28
- "oclif": "^4.15.9",
28
+ "oclif": "^4.15.12",
29
29
  "ts-node": "^10.9.2",
30
30
  "typescript": "^5.6.3"
31
31
  },
@@ -80,14 +80,6 @@
80
80
  }
81
81
  },
82
82
  "external": true
83
- },
84
- "force": {
85
- "external": true,
86
- "subtopics": {
87
- "org": {
88
- "description": "Manage your sandbox and scratch orgs."
89
- }
90
- }
91
83
  }
92
84
  },
93
85
  "flexibleTaxonomy": true,
@@ -108,7 +100,6 @@
108
100
  "prepare": "sf-install",
109
101
  "test": "wireit",
110
102
  "test:nuts": "nyc mocha \"./test/nut/*.nut.ts\" --slow 4500 --timeout 1200000 --parallel --jobs 2",
111
- "test:nuts:legacy": "nyc mocha \"./test/nut/legacy/*.nut.ts\" --slow 4500 --timeout 1200000 --parallel --jobs 5",
112
103
  "test:nuts:sandbox": "nyc mocha \"./test/**/*.sandboxNut.ts\" --slow 450000 --timeout 7200000 --parallel --jobs 5",
113
104
  "test:only": "wireit",
114
105
  "test:watch": "mocha --watch \"./test/**/*.test.ts\"",
@@ -235,7 +226,7 @@
235
226
  "exports": "./lib/index.js",
236
227
  "type": "module",
237
228
  "sfdx": {
238
- "publicKeyUrl": "https://developer.salesforce.com/media/salesforce-cli/security/@salesforce/plugin-org/4.8.2.crt",
239
- "signatureUrl": "https://developer.salesforce.com/media/salesforce-cli/security/@salesforce/plugin-org/4.8.2.sig"
229
+ "publicKeyUrl": "https://developer.salesforce.com/media/salesforce-cli/security/@salesforce/plugin-org/5.0.1.crt",
230
+ "signatureUrl": "https://developer.salesforce.com/media/salesforce-cli/security/@salesforce/plugin-org/5.0.1.sig"
240
231
  }
241
232
  }
@@ -1,76 +0,0 @@
1
- import Interfaces from '@oclif/core/interfaces';
2
- import { SfCommand } from '@salesforce/sf-plugins-core';
3
- import { AuthFields, OrgTypes, SandboxProcessObject, ScratchOrgInfo } from '@salesforce/core';
4
- export type ScratchOrgProcessObject = {
5
- username?: string;
6
- scratchOrgInfo: ScratchOrgInfo;
7
- authFields?: AuthFields;
8
- warnings: string[];
9
- orgId: string;
10
- };
11
- export type CreateResult = ScratchOrgProcessObject | SandboxProcessObject;
12
- export declare class Create extends SfCommand<CreateResult> {
13
- static readonly summary: string;
14
- static readonly description: string;
15
- static readonly examples: string[];
16
- static state: string;
17
- static readonly hidden = true;
18
- static deprecationOptions: {
19
- message: string;
20
- };
21
- static readonly strict = false;
22
- static readonly flags: {
23
- 'target-org': {
24
- summary: string;
25
- name: string;
26
- char?: Interfaces.AlphabetLowercase | Interfaces.AlphabetUppercase;
27
- description?: string;
28
- helpLabel?: string;
29
- helpGroup?: string;
30
- env?: string;
31
- hidden?: boolean;
32
- required?: boolean;
33
- dependsOn?: string[];
34
- exclusive?: string[];
35
- exactlyOne?: string[];
36
- relationships?: import("node_modules/@oclif/core/lib/interfaces/parser.js").Relationship[];
37
- deprecated?: true | Interfaces.Deprecation;
38
- aliases?: string[];
39
- charAliases?: (Interfaces.AlphabetLowercase | Interfaces.AlphabetUppercase)[];
40
- deprecateAliases?: boolean;
41
- noCacheDefault?: boolean;
42
- type: "option";
43
- helpValue?: string | string[];
44
- options?: readonly string[];
45
- multiple?: boolean;
46
- multipleNonGreedy?: boolean;
47
- delimiter?: ",";
48
- allowStdin?: boolean | "only";
49
- parse: import("node_modules/@oclif/core/lib/interfaces/parser.js").FlagParser<import("@salesforce/core").Org | undefined, string, Interfaces.CustomOptions>;
50
- defaultHelp?: import("node_modules/@oclif/core/lib/interfaces/parser.js").FlagDefaultHelp<import("@salesforce/core").Org, Interfaces.CustomOptions> | undefined;
51
- input: string[];
52
- default?: import("node_modules/@oclif/core/lib/interfaces/parser.js").FlagDefault<import("@salesforce/core").Org | undefined, Interfaces.CustomOptions>;
53
- };
54
- 'target-dev-hub': Interfaces.OptionFlag<import("@salesforce/core").Org | undefined, Interfaces.CustomOptions>;
55
- 'api-version': Interfaces.OptionFlag<string | undefined, Interfaces.CustomOptions>;
56
- loglevel: Interfaces.OptionFlag<string | undefined, Interfaces.CustomOptions>;
57
- type: Interfaces.OptionFlag<OrgTypes, Interfaces.CustomOptions>;
58
- definitionfile: Interfaces.OptionFlag<string | undefined, Interfaces.CustomOptions>;
59
- nonamespace: Interfaces.BooleanFlag<boolean>;
60
- noancestors: Interfaces.BooleanFlag<boolean>;
61
- clientid: Interfaces.OptionFlag<string | undefined, Interfaces.CustomOptions>;
62
- setdefaultusername: Interfaces.BooleanFlag<boolean>;
63
- setalias: Interfaces.OptionFlag<string | undefined, Interfaces.CustomOptions>;
64
- wait: Interfaces.OptionFlag<import("@salesforce/kit").Duration, Interfaces.CustomOptions>;
65
- durationdays: Interfaces.OptionFlag<number, Interfaces.CustomOptions>;
66
- retry: Interfaces.OptionFlag<number, Interfaces.CustomOptions>;
67
- };
68
- private sandboxAuth?;
69
- private logger;
70
- private varArgs;
71
- private flags;
72
- run(): Promise<CreateResult>;
73
- private validateSandboxFlags;
74
- private createSandbox;
75
- private createScratchOrg;
76
- }
@@ -1,241 +0,0 @@
1
- /*
2
- * Copyright (c) 2021, salesforce.com, inc.
3
- * All rights reserved.
4
- * Licensed under the BSD 3-Clause license.
5
- * For full license text, see LICENSE.txt file in the repo root or https://opensource.org/licenses/BSD-3-Clause
6
- */
7
- import { Flags, loglevel, optionalHubFlagWithDeprecations, optionalOrgFlagWithDeprecations, orgApiVersionFlagWithDeprecations, parseVarArgs, SfCommand, } from '@salesforce/sf-plugins-core';
8
- import { Lifecycle, Logger, Messages, OrgConfigProperties, OrgTypes, SandboxEvents, SfError, StateAggregator, } from '@salesforce/core';
9
- import requestFunctions from '../../../shared/sandboxRequest.js';
10
- import { SandboxReporter } from '../../../shared/sandboxReporter.js';
11
- Messages.importMessagesDirectoryFromMetaUrl(import.meta.url);
12
- const messages = Messages.loadMessages('@salesforce/plugin-org', 'create');
13
- export class Create extends SfCommand {
14
- static summary = messages.getMessage('summary');
15
- static description = messages.getMessage('description');
16
- static examples = messages.getMessages('examples');
17
- static state = 'deprecated';
18
- static hidden = true;
19
- static deprecationOptions = {
20
- message: messages.getMessage('deprecation'),
21
- };
22
- // needed to allow varargs
23
- static strict = false;
24
- static flags = {
25
- 'target-org': {
26
- ...optionalOrgFlagWithDeprecations,
27
- summary: messages.getMessage('flags.targetOrg.summary'),
28
- },
29
- 'target-dev-hub': optionalHubFlagWithDeprecations,
30
- 'api-version': orgApiVersionFlagWithDeprecations,
31
- loglevel,
32
- type: Flags.custom({
33
- options: [OrgTypes.Scratch, OrgTypes.Sandbox],
34
- })({
35
- char: 't',
36
- summary: messages.getMessage('flags.type.summary'),
37
- default: OrgTypes.Scratch,
38
- }),
39
- definitionfile: Flags.file({
40
- exists: true,
41
- char: 'f',
42
- summary: messages.getMessage('flags.definitionfile.summary'),
43
- }),
44
- nonamespace: Flags.boolean({
45
- char: 'n',
46
- summary: messages.getMessage('flags.nonamespace.summary'),
47
- }),
48
- noancestors: Flags.boolean({
49
- char: 'c',
50
- summary: messages.getMessage('flags.noancestors.summary'),
51
- }),
52
- clientid: Flags.string({
53
- char: 'i',
54
- summary: messages.getMessage('flags.clientid.summary'),
55
- }),
56
- setdefaultusername: Flags.boolean({
57
- char: 's',
58
- summary: messages.getMessage('flags.setdefaultusername.summary'),
59
- }),
60
- setalias: Flags.string({
61
- char: 'a',
62
- summary: messages.getMessage('flags.setalias.summary'),
63
- }),
64
- wait: Flags.duration({
65
- unit: 'minutes',
66
- char: 'w',
67
- summary: messages.getMessage('flags.wait.summary'),
68
- min: 6,
69
- defaultValue: 6,
70
- }),
71
- durationdays: Flags.integer({
72
- char: 'd',
73
- summary: messages.getMessage('flags.durationdays.summary'),
74
- min: 1,
75
- max: 30,
76
- default: 7,
77
- }),
78
- retry: Flags.integer({
79
- hidden: true,
80
- default: 0,
81
- max: 10,
82
- summary: messages.getMessage('flags.retry.summary'),
83
- }),
84
- };
85
- sandboxAuth;
86
- logger;
87
- varArgs = {};
88
- flags;
89
- async run() {
90
- const { flags, args, argv } = await this.parse(Create);
91
- this.flags = flags;
92
- this.varArgs = parseVarArgs(args, argv);
93
- this.logger = await Logger.child(this.constructor.name);
94
- if (flags.type === OrgTypes.Sandbox) {
95
- this.validateSandboxFlags();
96
- return this.createSandbox();
97
- }
98
- else {
99
- // default to scratch org
100
- return this.createScratchOrg();
101
- }
102
- }
103
- validateSandboxFlags() {
104
- if (this.flags.retry !== 0) {
105
- throw new SfError(messages.getMessage('retryIsNotValidForSandboxes'), 'retryIsNotValidForSandboxes');
106
- }
107
- if (this.flags.clientid) {
108
- this.warn(messages.getMessage('clientIdNotSupported', [this.flags.clientid]));
109
- }
110
- if (this.flags.nonamespace) {
111
- this.warn(messages.getMessage('noNamespaceNotSupported', [this.flags.nonamespace]));
112
- }
113
- if (this.flags.noancestors) {
114
- this.warn(messages.getMessage('noAncestorsNotSupported', [this.flags.noancestors]));
115
- }
116
- if (this.flags.durationdays) {
117
- this.warn(messages.getMessage('durationDaysNotSupported', [this.flags.durationdays]));
118
- }
119
- }
120
- async createSandbox() {
121
- if (!this.flags['target-org']) {
122
- throw new SfError(messages.getMessage('requiresUsername', [this.config.bin]));
123
- }
124
- const lifecycle = Lifecycle.getInstance();
125
- const username = this.flags['target-org'].getUsername();
126
- // register the sandbox event listeners before calling `prodOrg.createSandbox()`
127
- lifecycle.on(SandboxEvents.EVENT_ASYNC_RESULT, async (results) => Promise.resolve(this.log(messages.getMessage('sandboxSuccess', [results.Id, this.config.bin, results.SandboxName, username]))));
128
- lifecycle.on(SandboxEvents.EVENT_STATUS, async (results) => Promise.resolve(this.log(SandboxReporter.sandboxProgress(results))));
129
- lifecycle.on(SandboxEvents.EVENT_AUTH, async (results) => {
130
- this.sandboxAuth = results;
131
- return Promise.resolve();
132
- });
133
- lifecycle.on(SandboxEvents.EVENT_RESULT, async (results) => {
134
- const { sandboxReadyForUse, data } = SandboxReporter.logSandboxProcessResult(results);
135
- this.log(sandboxReadyForUse);
136
- this.table({
137
- data,
138
- columns: [{ key: 'key', name: 'Name' }, 'value'],
139
- title: 'Sandbox Org Creation Status',
140
- });
141
- if (results.sandboxRes?.authUserName) {
142
- if (this.flags.setalias) {
143
- const stateAggregator = await StateAggregator.getInstance();
144
- await stateAggregator.aliases.setAndSave(this.flags.setalias, results.sandboxRes.authUserName);
145
- this.logger.debug('Set Alias: %s result: %s', this.flags.setalias, stateAggregator.aliases.getAll());
146
- }
147
- if (this.flags.setdefaultusername) {
148
- const globalConfig = this.configAggregator.getGlobalConfig();
149
- globalConfig.set(OrgConfigProperties.TARGET_ORG, results.sandboxRes.authUserName);
150
- const result = await globalConfig.write();
151
- this.logger.debug('Set defaultUsername: %s result: %s', this.flags.setdefaultusername, result);
152
- }
153
- }
154
- });
155
- const { sandboxReq } = await requestFunctions.createSandboxRequest(false, this.flags.definitionfile, this.logger, this.varArgs);
156
- this.logger.debug('Calling create with SandboxRequest: %s ', sandboxReq);
157
- const wait = this.flags.wait;
158
- try {
159
- return await this.flags['target-org'].createSandbox(sandboxReq, { wait });
160
- }
161
- catch (e) {
162
- // guaranteed to be SfError from core;
163
- const err = e;
164
- if (err?.message.includes('The org cannot be found')) {
165
- // there was most likely an issue with DNS when auth'ing to the new sandbox, but it was created.
166
- if (this.flags.setalias && this.sandboxAuth) {
167
- const stateAggregator = await StateAggregator.getInstance();
168
- await stateAggregator.aliases.setAndSave(this.flags.setalias, this.sandboxAuth.authUserName);
169
- this.logger.debug('Set Alias: %s result: %s', this.flags.setalias, stateAggregator.aliases.getAll());
170
- }
171
- if (this.flags.setdefaultusername && this.sandboxAuth) {
172
- const globalConfig = this.configAggregator.getGlobalConfig();
173
- globalConfig.set(OrgConfigProperties.TARGET_ORG, this.sandboxAuth.authUserName);
174
- const result = await globalConfig.write();
175
- this.logger.debug('Set defaultUsername: %s result: %s', this.flags.setdefaultusername, result);
176
- }
177
- err.actions = [
178
- messages.getMessage('dnsTimeout', [this.config.bin, this.config.bin]),
179
- messages.getMessage('partialSuccess', [this.config.bin, this.config.bin, this.config.bin]),
180
- ];
181
- err.exitCode = 68;
182
- }
183
- throw err;
184
- }
185
- }
186
- async createScratchOrg() {
187
- this.logger.debug('OK, will do scratch org creation');
188
- if (!this.flags['target-dev-hub']) {
189
- throw new SfError(messages.getMessage('RequiresDevhubUsernameError'));
190
- }
191
- // Ensure we have an org config input source.
192
- if (!this.flags.definitionfile && Object.keys(this.varArgs).length === 0) {
193
- throw new SfError(messages.getMessage('noConfig'));
194
- }
195
- this.logger.debug('validation complete');
196
- const createCommandOptions = {
197
- connectedAppConsumerKey: this.flags.clientid,
198
- durationDays: this.flags.durationdays,
199
- nonamespace: this.flags.nonamespace,
200
- noancestors: this.flags.noancestors,
201
- wait: this.flags.wait,
202
- retry: this.flags.retry,
203
- apiversion: this.flags['api-version'],
204
- definitionfile: this.flags.definitionfile,
205
- orgConfig: this.varArgs,
206
- // If the user supplied a specific client ID, we have no way of knowing if it's
207
- // a certificate-based Connected App or not. Therefore, we have to assume that
208
- // we'll need the client secret, so prompt the user for it.
209
- clientSecret: this.flags.clientid
210
- ? await this.secretPrompt({ message: messages.getMessage('secretPrompt') })
211
- : undefined,
212
- setDefault: this.flags.setdefaultusername === true,
213
- alias: this.flags.setalias,
214
- tracksSource: true,
215
- };
216
- const { username, scratchOrgInfo, authFields, warnings } = await this.flags['target-dev-hub'].scratchOrgCreate(createCommandOptions);
217
- if (!scratchOrgInfo) {
218
- throw new SfError('No scratch org info returned from scratchOrgCreate');
219
- }
220
- if (!authFields?.orgId) {
221
- throw new SfError('Information missing from authFields');
222
- }
223
- await Lifecycle.getInstance().emit('scratchOrgInfo', scratchOrgInfo);
224
- this.logger.debug(`orgConfig.loginUrl: ${authFields?.loginUrl ?? '<not found>'}`);
225
- this.logger.debug(`orgConfig.instanceUrl: ${authFields?.instanceUrl ?? '<not found>'}`);
226
- this.log(messages.getMessage('scratchOrgCreateSuccess', [authFields?.orgId, username]));
227
- if (warnings.length > 0) {
228
- warnings.forEach((warning) => {
229
- this.warn(warning);
230
- });
231
- }
232
- return {
233
- username,
234
- scratchOrgInfo,
235
- authFields,
236
- warnings,
237
- orgId: authFields?.orgId,
238
- };
239
- }
240
- }
241
- //# sourceMappingURL=create.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"create.js","sourceRoot":"","sources":["../../../../src/commands/force/org/create.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAGH,OAAO,EACL,KAAK,EACL,QAAQ,EACR,+BAA+B,EAC/B,+BAA+B,EAC/B,iCAAiC,EACjC,YAAY,EACZ,SAAS,GACV,MAAM,6BAA6B,CAAC;AACrC,OAAO,EAGL,SAAS,EACT,MAAM,EACN,QAAQ,EACR,mBAAmB,EACnB,QAAQ,EAER,aAAa,EAKb,OAAO,EACP,eAAe,GAEhB,MAAM,kBAAkB,CAAC;AAC1B,OAAO,gBAAgB,MAAM,mCAAmC,CAAC;AACjE,OAAO,EAAE,eAAe,EAAE,MAAM,oCAAoC,CAAC;AAErE,QAAQ,CAAC,kCAAkC,CAAC,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;AAC7D,MAAM,QAAQ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eleteResult = {
3
- orgId: string;
4
- username: string;
5
- };
6
- export declare class Delete extends SfCommand<DeleteResult> {
7
- static readonly summary: string;
8
- static readonly description: string;
9
- static readonly examples: string[];
10
- static state: string;
11
- static readonly hidden = true;
12
- static deprecationOptions: {
13
- message: string;
14
- };
15
- static readonly flags: {
16
- 'target-org': import("@oclif/core/interfaces").OptionFlag<string, import("@oclif/core/interfaces").CustomOptions>;
17
- targetdevhubusername: import("@oclif/core/interfaces").OptionFlag<string | undefined, import("@oclif/core/interfaces").CustomOptions>;
18
- 'api-version': import("@oclif/core/interfaces").OptionFlag<string | undefined, import("@oclif/core/interfaces").CustomOptions>;
19
- 'no-prompt': import("@oclif/core/interfaces").BooleanFlag<boolean>;
20
- loglevel: import("@oclif/core/interfaces").OptionFlag<string | undefined, import("@oclif/core/interfaces").CustomOptions>;
21
- };
22
- run(): Promise<DeleteResult>;
23
- }
@@ -1,88 +0,0 @@
1
- /*
2
- * Copyright (c) 2020, salesforce.com, inc.
3
- * All rights reserved.
4
- * Licensed under the BSD 3-Clause license.
5
- * For full license text, see LICENSE.txt file in the repo root or https://opensource.org/licenses/BSD-3-Clause
6
- */
7
- import { Flags, loglevel, orgApiVersionFlagWithDeprecations, SfCommand } from '@salesforce/sf-plugins-core';
8
- import { AuthInfo, AuthRemover, Messages, Org, StateAggregator } from '@salesforce/core';
9
- import { orgThatMightBeDeleted } from '../../../shared/flags.js';
10
- Messages.importMessagesDirectoryFromMetaUrl(import.meta.url);
11
- const messages = Messages.loadMessages('@salesforce/plugin-org', 'delete');
12
- export class Delete extends SfCommand {
13
- static summary = messages.getMessage('summary');
14
- static description = messages.getMessage('description');
15
- static examples = messages.getMessages('examples');
16
- static state = 'deprecated';
17
- static hidden = true;
18
- static deprecationOptions = {
19
- message: messages.getMessage('deprecation'),
20
- };
21
- static flags = {
22
- 'target-org': orgThatMightBeDeleted({
23
- required: true,
24
- summary: messages.getMessage('flags.target-org.summary'),
25
- }),
26
- targetdevhubusername: Flags.string({
27
- summary: messages.getMessage('flags.targetdevhubusername.summary'),
28
- char: 'v',
29
- hidden: true,
30
- deprecated: {
31
- version: '58.0',
32
- message: messages.getMessage('flags.targetdevhubusername.summary'),
33
- },
34
- }),
35
- 'api-version': orgApiVersionFlagWithDeprecations,
36
- 'no-prompt': Flags.boolean({
37
- char: 'p',
38
- summary: messages.getMessage('flags.no-prompt.summary'),
39
- deprecateAliases: true,
40
- aliases: ['noprompt'],
41
- }),
42
- loglevel,
43
- };
44
- async run() {
45
- const { flags } = await this.parse(Delete);
46
- const resolvedUsername = flags['target-org'];
47
- const orgId = (await AuthInfo.create({ username: resolvedUsername })).getFields().orgId;
48
- const isSandbox = await (await StateAggregator.getInstance()).sandboxes.hasFile(orgId);
49
- // read the config file for the org to be deleted, if it has a PROD_ORG_USERNAME entry, it's a sandbox
50
- // we either need permission to proceed without a prompt OR get the user to confirm
51
- if (flags['no-prompt'] ||
52
- (await this.confirm({
53
- message: messages.getMessage('confirmDelete', [isSandbox ? 'sandbox' : 'scratch', resolvedUsername]),
54
- }))) {
55
- let alreadyDeleted = false;
56
- let successMessageKey = 'commandSandboxSuccess';
57
- try {
58
- const org = await Org.create({ aliasOrUsername: resolvedUsername });
59
- // will determine if it's a scratch org or sandbox and will delete from the appropriate parent org (DevHub or Production)
60
- await org.delete();
61
- }
62
- catch (e) {
63
- if (e instanceof Error && e.name === 'DomainNotFoundError') {
64
- // the org has expired, so remote operations won't work
65
- // let's clean up the files locally
66
- const authRemover = await AuthRemover.create();
67
- await authRemover.removeAuth(resolvedUsername);
68
- }
69
- else if (e instanceof Error && e.name === 'ScratchOrgNotFound') {
70
- alreadyDeleted = true;
71
- }
72
- else if (e instanceof Error && e.name === 'SandboxNotFound') {
73
- successMessageKey = 'sandboxConfigOnlySuccess';
74
- }
75
- else {
76
- throw e;
77
- }
78
- }
79
- this.log(isSandbox
80
- ? messages.getMessage(successMessageKey, [resolvedUsername])
81
- : messages.getMessage(alreadyDeleted ? 'deleteOrgConfigOnlyCommandSuccess' : 'deleteOrgCommandSuccess', [
82
- resolvedUsername,
83
- ]));
84
- }
85
- return { username: resolvedUsername, orgId };
86
- }
87
- }
88
- //# sourceMappingURL=delete.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"delete.js","sourceRoot":"","sources":["../../../../src/commands/force/org/delete.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,EAAE,KAAK,EAAE,QAAQ,EAAE,iCAAiC,EAAE,SAAS,EAAE,MAAM,6BAA6B,CAAC;AAC5G,OAAO,EAAE,QAAQ,EAAE,WAAW,EAAE,QAAQ,EAAE,GAAG,EAAE,eAAe,EAAE,MAAM,kBAAkB,CAAC;AACzF,OAAO,EAAE,qBAAqB,EAAE,MAAM,0BAA0B,CAAC;AAEjE,QAAQ,CAAC,kCAAkC,CAAC,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;AAC7D,MAAM,QAAQ,GAAG,QAAQ,CAAC,YAAY,CAAC,wBAAwB,EAAE,QAAQ,CAAC,CAAC;AAO3E,MAAM,OAAO,MAAO,SAAQ,SAAuB;IAC1C,MAAM,CAAU,OAAO,GAAG,QAAQ,CAAC,UAAU,CAAC,SAAS,CAAC,CAAC;IACzD,MAAM,CAAU,WAAW,GAAG,QAAQ,CAAC,UAAU,CAAC,aAAa,CAAC,CAAC;IACjE,MAAM,CAAU,QAAQ,GAAG,QAAQ,CAAC,WAAW,CAAC,UAAU,CAAC,CAAC;IAC5D,MAAM,CAAC,KAAK,GAAG,YAAY,CAAC;IAC5B,MAAM,CAAU,MAAM,GAAG,IAAI,CAAC;IAC9B,MAAM,CAAC,kBAAkB,GAAG;QACjC,OAAO,EAAE,QAAQ,CAAC,UAAU,CAAC,aAAa,CAAC;KAC5C,CAAC;IACK,MAAM,CAAU,KAAK,GAAG;QAC7B,YAAY,EAAE,qBAAqB,CAAC;YAClC,QAAQ,EAAE,IAAI;YACd,OAAO,EAAE,QAAQ,CAAC,UAAU,CAAC,0BAA0B,CAAC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,0 @@
1
- # summary
2
-
3
- Create a scratch org or sandbox.
4
-
5
- # deprecation
6
-
7
- The force:org:create command is deprecated and will be removed on November 6, 2024. Use "org create scratch" or "org create sandbox" instead.
8
-
9
- # description
10
-
11
- Creates a scratch org or a sandbox org using the values specified in a configuration file or key=value pairs that you specify on the command line. Values specified on the command line override values in the configuration file. Specify a configuration file or provide key=value pairs while creating a scratch org or a sandbox. When creating scratch orgs, —targetdevhubusername (-v) must be a Dev Hub org. When creating sandboxes, the --targetusername (-u) must be a production org with sandbox licenses. The —type (-t) is required if creating a sandbox.
12
-
13
- # examples
14
-
15
- - $ <%= config.bin %> <%= command.id %> -f config/enterprise-scratch-def.json -a MyScratchOrg
16
-
17
- - $ <%= config.bin %> <%= command.id %> edition=Developer -a MyScratchOrg -s -v devHub
18
-
19
- - $ <%= config.bin %> <%= command.id %> -f config/enterprise-scratch-def.json -a ScratchOrgWithOverrides username=testuser1@mycompany.org
20
-
21
- - $ <%= config.bin %> <%= command.id %> -t sandbox -f config/dev-sandbox-def.json -a MyDevSandbox -u prodOrg
22
-
23
- # flags.clientid.summary
24
-
25
- Connected app consumer key; not supported for sandbox org creation.
26
-
27
- # flags.setdefaultusername.summary
28
-
29
- Set the created org as the default username.
30
-
31
- # flags.setalias.summary
32
-
33
- Alias for the created org.
34
-
35
- # flags.definitionfile.summary
36
-
37
- Path to an org definition file.
38
-
39
- # flags.nonamespace.summary
40
-
41
- Create the scratch org with no namespace.
42
-
43
- # flags.noancestors.summary
44
-
45
- Do not include second-generation package ancestors in the scratch org.
46
-
47
- # flags.type.summary
48
-
49
- Type of org to create.
50
-
51
- # flags.durationdays.summary
52
-
53
- Duration of the scratch org (in days) (default:7, min:1, max:30).
54
-
55
- # flags.retry.summary
56
-
57
- Number of scratch org auth retries after scratch org is successfully signed up.
58
-
59
- # flags.wait.summary
60
-
61
- Streaming client socket timeout (in minutes).
62
-
63
- # flags.targetOrg.summary
64
-
65
- Username or alias of the production org that contains the sandbox license.
66
-
67
- # scratchOrgCreateSuccess
68
-
69
- Successfully created scratch org: %s, username: %s.
70
-
71
- # clientIdNotSupported
72
-
73
- -i | --clientid is not supported for the sandbox org create command. Its value, %s, has been ignored.
74
-
75
- # noNamespaceNotSupported
76
-
77
- -n | --nonamespace is not supported for the sandbox org create command. Its value, %s, has been ignored.
78
-
79
- # noAncestorsNotSupported
80
-
81
- -c | --noancestors is not supported for the sandbox org create command. Its value, %s, has been ignored.
82
-
83
- # durationDaysNotSupported
84
-
85
- -d | --durationdays is not supported for the sandbox org create command. Its value, %s, has been ignored.
86
-
87
- # retryIsNotValidForSandboxes
88
-
89
- One cannot use flag retry with Sandbox org create.
90
-
91
- # sandboxSuccess
92
-
93
- The sandbox org creation process %s is in progress. Run "%s force:org:status -n %s -u %s" to check for status. If the org is ready, checking the status also authorizes the org for use with Salesforce CLI.
94
-
95
- # requiresUsername
96
-
97
- This command requires a username. Specify it with the -u parameter or with the "%s config set defaultusername=<username>" command.
98
-
99
- # dnsTimeout
100
-
101
- The sandbox was successfully created and authenticated. However, the sandbox DNS records aren't ready yet and so the sandbox may not be available. Run "%s org:list" and check if the sandbox is listed correctly. If it isn't listed, run "%s force:org:status" to view its status and, if necessary, authenticate to it again. If this issue happens frequently, try setting the SFDX_DNS_TIMEOUT environment variable to a larger number; the default value is 3 seconds.
102
-
103
- # partialSuccess
104
-
105
- If you specified the -a or -s parameters, but the sandbox wasn't immediately available, the "%s force:org:create" command may not have finished setting the alias or defaultusername. If so, set the alias manually with "%s alias:set" and the defaultusername with "%s config:set".
106
-
107
- # noConfig
108
-
109
- Please specify an org configuration via file and/or key=value pairs.
110
-
111
- # RequiresDevhubUsernameError
112
-
113
- This command requires a dev hub org username set either with a flag or by default in the config.
114
-
115
- # secretPrompt
116
-
117
- OAuth client secret of personal connected app?
@@ -1,60 +0,0 @@
1
- # summary
2
-
3
- Delete a scratch or sandbox org.
4
-
5
- # deprecation
6
-
7
- The force:org:delete command is deprecated and will be removed on November 6, 2024. Use "org delete scratch" or "org delete sandbox" instead.
8
-
9
- # description
10
-
11
- Salesforce CLI marks the org for deletion in either the Dev Hub org (for scratch orgs) or production org (for sandboxes) and then deletes all local references to the org from your computer.
12
-
13
- To mark the org for deletion without being prompted to confirm, specify --noprompt.
14
-
15
- # examples
16
-
17
- - $ <%= config.bin %> <%= command.id %> -u me@my.org
18
-
19
- - $ <%= config.bin %> <%= command.id %> -u MyOrgAlias -p
20
-
21
- # flags.no-prompt.summary
22
-
23
- No prompt to confirm deletion.
24
-
25
- # missingUsername
26
-
27
- Unable to determine the username of the org to delete. Specify the username with the --target-org | -o flag.
28
-
29
- # flags.target-org.summary
30
-
31
- Username or alias of the target org.
32
-
33
- # flags.targetdevhubusername.summary
34
-
35
- The targetdevhubusername flag exists only for backwards compatibility. It is not necessary and has no effect.
36
-
37
- # confirmDelete
38
-
39
- Enqueue %s org with name: %s for deletion? Are you sure (y/n)?
40
-
41
- # sandboxConfigOnlySuccess
42
-
43
- Successfully deleted sandbox org %s.
44
-
45
- # ScratchOrgNotFound
46
-
47
- Attempting to delete an expired or deleted org
48
-
49
- # deleteOrgConfigOnlyCommandSuccess
50
-
51
- Successfully deleted scratch org %s.'
52
-
53
- # deleteOrgCommandSuccess
54
-
55
- Successfully marked scratch org %s for deletion
56
-
57
- # commandSandboxSuccess
58
-
59
- The sandbox org %s has been successfully removed from your list of CLI authorized orgs. If you created the sandbox with
60
- one of the force:org commands, it has also been marked for deletion.