@salesforce/plugin-deploy-retrieve 3.24.2 → 3.24.3

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.
Files changed (53) hide show
  1. package/LICENSE.txt +1 -1
  2. package/README.md +53 -23
  3. package/lib/commands/project/convert/mdapi.js +1 -1
  4. package/lib/commands/project/convert/source-behavior.js +1 -1
  5. package/lib/commands/project/convert/source.js +1 -1
  6. package/lib/commands/project/delete/source.js +1 -1
  7. package/lib/commands/project/delete/tracking.js +1 -1
  8. package/lib/commands/project/deploy/cancel.js +1 -1
  9. package/lib/commands/project/deploy/preview.js +1 -1
  10. package/lib/commands/project/deploy/quick.js +1 -1
  11. package/lib/commands/project/deploy/report.js +1 -1
  12. package/lib/commands/project/deploy/resume.js +1 -1
  13. package/lib/commands/project/deploy/start.js +1 -1
  14. package/lib/commands/project/deploy/validate.js +1 -1
  15. package/lib/commands/project/generate/manifest.js +1 -1
  16. package/lib/commands/project/list/ignored.js +1 -1
  17. package/lib/commands/project/reset/tracking.js +1 -1
  18. package/lib/commands/project/retrieve/preview.js +1 -1
  19. package/lib/commands/project/retrieve/start.js +1 -1
  20. package/lib/configMeta.js +1 -1
  21. package/lib/formatters/asyncDeployCancelResultFormatter.js +1 -1
  22. package/lib/formatters/asyncDeployResultFormatter.js +1 -1
  23. package/lib/formatters/deleteResultFormatter.js +1 -1
  24. package/lib/formatters/deployCancelResultFormatter.js +1 -1
  25. package/lib/formatters/deployReportResultFormatter.js +1 -1
  26. package/lib/formatters/deployResultFormatter.js +1 -1
  27. package/lib/formatters/metadataConvertResultFormatter.js +1 -1
  28. package/lib/formatters/metadataRetrieveResultFormatter.js +1 -1
  29. package/lib/formatters/retrieveResultFormatter.js +1 -1
  30. package/lib/formatters/sourceConvertResultFormatter.js +1 -1
  31. package/lib/formatters/testResultsFormatter.js +1 -1
  32. package/lib/hooks/diagnostics.js +1 -1
  33. package/lib/index.js +1 -1
  34. package/lib/utils/conflicts.js +1 -1
  35. package/lib/utils/convertBehavior.js +1 -1
  36. package/lib/utils/coverage.js +1 -1
  37. package/lib/utils/deploy.js +1 -1
  38. package/lib/utils/deployCache.js +1 -1
  39. package/lib/utils/deployStages.js +1 -1
  40. package/lib/utils/errorCodes.js +1 -1
  41. package/lib/utils/flags.js +1 -1
  42. package/lib/utils/manifestCache.js +1 -1
  43. package/lib/utils/metadataTypes.js +1 -1
  44. package/lib/utils/output.js +1 -1
  45. package/lib/utils/previewOutput.js +1 -1
  46. package/lib/utils/project.js +1 -1
  47. package/lib/utils/promiseQueue.js +1 -1
  48. package/lib/utils/types.js +1 -1
  49. package/messages/delete.source.md +3 -1
  50. package/messages/deploy.metadata.md +2 -2
  51. package/messages/deploy.metadata.validate.md +3 -1
  52. package/oclif.manifest.json +1044 -1044
  53. package/package.json +5 -5
@@ -405,16 +405,18 @@
405
405
  "source:convert:project"
406
406
  ]
407
407
  },
408
- "project:deploy:cancel": {
408
+ "project:delete:source": {
409
409
  "aliases": [
410
- "deploy:metadata:cancel"
410
+ "force:source:delete"
411
411
  ],
412
412
  "args": {},
413
413
  "deprecateAliases": true,
414
- "description": "Use this command to cancel a deploy operation that hasn't yet completed in the org. Deploy operations include standard deploys, quick deploys, deploy validations, and deploy cancellations.\n\nRun this command by either passing it a job ID or specifying the --use-most-recent flag to use the job ID of the most recent deploy operation.",
414
+ "description": "Use this command to delete components from orgs that don’t have source tracking. To remove deleted items from orgs that have source tracking enabled, \"<%= config.bin %> project deploy start\".\n\nWhen you run this command, both the local source file and the metadata component in the org are deleted.\n\nTo delete multiple metadata components, either set multiple --metadata <name> flags or a single --metadata flag with multiple names separated by spaces. Enclose names that contain spaces in one set of double quotes. The same syntax applies to --source-dir.",
415
415
  "examples": [
416
- "Cancel a deploy operation using a job ID:\n<%= config.bin %> <%= command.id %> --job-id 0Af0x000017yLUFCA2",
417
- "Cancel the most recent deploy operation:\n<%= config.bin %> <%= command.id %> --use-most-recent"
416
+ "Delete all local Apex source files and all Apex classes from the org with alias \"my-scratch\":\n<%= config.bin %> <%= command.id %> --metadata ApexClass --target-org my-scratch",
417
+ "Delete a specific Apex class and a Profile that has a space in it from your default org; don't prompt for confirmation:\n<%= config.bin %> <%= command.id %> --metadata ApexClass:MyFabulousApexClass --metadata \"Profile: My Profile\" --no-prompt",
418
+ "Run the tests that aren’t in any managed packages as part of the deletion; if the delete succeeds, and the org has source-tracking enabled, update the source tracking information:\n<%= config.bin %> <%= command.id %> --metadata ApexClass --test-level RunLocalTests --track-source",
419
+ "Delete the Apex source files in a directory and the corresponding components from your default org:\n<%= config.bin %> <%= command.id %> --source-dir force-app/main/default/classes"
418
420
  ],
419
421
  "flags": {
420
422
  "json": {
@@ -432,103 +434,207 @@
432
434
  "multiple": false,
433
435
  "type": "option"
434
436
  },
437
+ "api-version": {
438
+ "aliases": [
439
+ "apiversion"
440
+ ],
441
+ "deprecateAliases": true,
442
+ "description": "Override the api version used for api requests made by this command",
443
+ "name": "api-version",
444
+ "hasDynamicHelp": false,
445
+ "multiple": false,
446
+ "type": "option"
447
+ },
448
+ "loglevel": {
449
+ "deprecated": {
450
+ "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."
451
+ },
452
+ "hidden": true,
453
+ "name": "loglevel",
454
+ "hasDynamicHelp": false,
455
+ "multiple": false,
456
+ "type": "option"
457
+ },
435
458
  "target-org": {
459
+ "aliases": [
460
+ "targetusername",
461
+ "u"
462
+ ],
436
463
  "char": "o",
464
+ "deprecateAliases": true,
437
465
  "name": "target-org",
438
466
  "noCacheDefault": true,
439
- "summary": "Username or alias of the target org.",
467
+ "required": true,
468
+ "summary": "Username or alias of the target org. Not required if the `target-org` configuration variable is already set.",
440
469
  "hasDynamicHelp": true,
441
470
  "multiple": false,
442
471
  "type": "option"
443
472
  },
444
- "async": {
445
- "description": "The command immediately returns the control of the terminal to you. This way, you can continue to use the CLI. To resume watching the cancellation, run \"<%= config.bin %> project deploy resume\". To check the status of the cancellation, run \"<%= config.bin %> project deploy report\".",
446
- "exclusive": [
447
- "wait"
473
+ "check-only": {
474
+ "aliases": [
475
+ "checkonly"
448
476
  ],
449
- "name": "async",
450
- "summary": "Run the command asynchronously.",
477
+ "char": "c",
478
+ "deprecateAliases": true,
479
+ "description": "IMPORTANT: Where possible, we changed noninclusive terms to align with our company value of Equality. We maintained certain terms to avoid any effect on customer implementations.\n\nValidates the deleted metadata and runs all Apex tests, but prevents the deletion from being saved to the org.\n\nIf you change a field type from Master-Detail to Lookup or vice versa, that change isn’t supported when using the --check-only flag to test a deletion (validation). This kind of change isn’t supported for test deletions to avoid the risk of data loss or corruption. If a change that isn’t supported for test deletions is included in a deletion package, the test deletion fails and issues an error.\n\nIf your deletion package changes a field type from Master-Detail to Lookup or vice versa, you can still validate the changes prior to deploying to Production by performing a full deletion to another test Sandbox. A full deletion includes a validation of the changes as part of the deletion process.\n\nNote: A Metadata API deletion that includes Master-Detail relationships deletes all detail records in the Recycle Bin in the following cases.\n\n 1. For a deletion with a new Master-Detail field, soft delete (send to the Recycle Bin) all detail records before proceeding to delete the Master-Detail field, or the deletion fails. During the deletion, detail records are permanently deleted from the Recycle Bin and cannot be recovered.\n\n 2. For a deletion that converts a Lookup field relationship to a Master-Detail relationship, detail records must reference a master record or be soft-deleted (sent to the Recycle Bin) for the deletion to succeed. However, a successful deletion permanently deletes any detail records in the Recycle Bin.",
480
+ "name": "check-only",
481
+ "summary": "Validate delete command but don't delete anything from the org or the local project.",
451
482
  "allowNo": false,
452
483
  "type": "boolean"
453
484
  },
454
- "job-id": {
455
- "char": "i",
456
- "description": "These commands return a job ID if they time out or you specified the --async flag:\n\n- <%= config.bin %> project deploy start\n- <%= config.bin %> project deploy validate\n- <%= config.bin %> project deploy quick\n- <%= config.bin %> project deploy cancel\n\nThe job ID is valid for 10 days from when you started the deploy operation.",
457
- "name": "job-id",
458
- "summary": "Job ID of the deploy operation you want to cancel.",
485
+ "wait": {
486
+ "char": "w",
487
+ "description": "If the command continues to run after the wait period, the CLI returns control of the terminal window to you.",
488
+ "name": "wait",
489
+ "summary": "Number of minutes to wait for the command to finish.",
490
+ "hasDynamicHelp": true,
491
+ "multiple": false,
492
+ "type": "option"
493
+ },
494
+ "tests": {
495
+ "description": "If a test name contains a space, enclose it in double quotes.\nFor multiple test names, use one of the following formats:\n\n- Repeat the flag for multiple test names: --tests Test1 --tests Test2 --tests \"Test With Space\"\n- Separate the test names with spaces: --tests Test1 Test2 \"Test With Space\"",
496
+ "helpGroup": "Test",
497
+ "name": "tests",
498
+ "summary": "Apex tests to run when --test-level is RunSpecifiedTests.",
499
+ "hasDynamicHelp": false,
500
+ "multiple": true,
501
+ "type": "option"
502
+ },
503
+ "test-level": {
504
+ "aliases": [
505
+ "testlevel"
506
+ ],
507
+ "char": "l",
508
+ "deprecateAliases": true,
509
+ "description": "Valid values are:\n\n- NoTestRun — No tests are run. This test level applies only to deployments to development environments, such as sandbox, Developer Edition, or trial orgs. This test level is the default for development environments.\n\n- RunSpecifiedTests — Runs only the tests that you specify with the --tests flag. Code coverage requirements differ from the default coverage requirements when using this test level. Executed tests must comprise a minimum of 75% code coverage for each class and trigger in the deployment package. This coverage is computed for each class and trigger individually and is different than the overall coverage percentage.\n\n- RunLocalTests — All tests in your org are run, except the ones that originate from installed managed and unlocked packages. This test level is the default for production deployments that include Apex classes or triggers.\n\n- RunAllTestsInOrg — All tests in your org are run, including tests of managed packages.\n\n- RunRelevantTests (Beta) — Runs only tests that are relevant to the files being deployed. Salesforce automatically identifies the relevant tests based on an analysis of the deployment payload and the payload dependencies. For fine-grained control, you can also annotate test classes so that they always run in certain conditions. See \"@IsTest Annotation\" in the \"Apex Developer Guide\" (https://developer.salesforce.com/docs/atlas.en-us.apexcode.meta/apexcode/apex_classes_annotation_isTest.htm). Each class and trigger in the deployment package must be covered by the executed tests for a minimum of 75% code coverage. This coverage is computed for each class and triggers individually and is different than the overall coverage percentage.\n\nIf you don’t specify a test level, the default behavior depends on the contents of your deployment package and target org. For more information, see \"Running Tests in a Deployment\" (https://developer.salesforce.com/docs/atlas.en-us.api_meta.meta/api_meta/meta_deploy_running_tests.htm) in the \"Metadata API Developer Guide\".",
510
+ "helpGroup": "Test",
511
+ "name": "test-level",
512
+ "summary": "Deployment Apex testing level.",
459
513
  "hasDynamicHelp": false,
460
514
  "multiple": false,
515
+ "options": [
516
+ "NoTestRun",
517
+ "RunSpecifiedTests",
518
+ "RunLocalTests",
519
+ "RunAllTestsInOrg",
520
+ "RunRelevantTests"
521
+ ],
461
522
  "type": "option"
462
523
  },
463
- "use-most-recent": {
524
+ "no-prompt": {
525
+ "aliases": [
526
+ "noprompt"
527
+ ],
464
528
  "char": "r",
465
- "description": "For performance reasons, this flag uses job IDs for deploy operations that started only in the past 3 days or less. If your most recent deploy operations was more than 3 days ago, this flag won't find a job ID.",
466
- "name": "use-most-recent",
467
- "summary": "Use the job ID of the most recent deploy operation.",
529
+ "deprecateAliases": true,
530
+ "name": "no-prompt",
531
+ "summary": "Don't prompt for delete confirmation.",
468
532
  "allowNo": false,
469
533
  "type": "boolean"
470
534
  },
471
- "wait": {
472
- "char": "w",
473
- "description": "If the command continues to run after the wait period, the CLI returns control of the terminal window to you. To resume watching the cancellation, run \"<%= config.bin %> project deploy resume\". To check the status of the cancellation, run \"<%= config.bin %> project deploy report\".",
474
- "exclusive": [
475
- "async"
535
+ "metadata": {
536
+ "char": "m",
537
+ "description": "If you specify this flag, don’t specify --source-dir.",
538
+ "name": "metadata",
539
+ "summary": "Metadata components to delete.",
540
+ "delimiter": ",",
541
+ "hasDynamicHelp": false,
542
+ "multiple": true,
543
+ "type": "option"
544
+ },
545
+ "source-dir": {
546
+ "aliases": [
547
+ "sourcepath"
476
548
  ],
477
- "name": "wait",
478
- "summary": "Number of minutes to wait for the command to complete and display results.",
479
- "hasDynamicHelp": true,
480
- "helpValue": "<minutes>",
481
- "multiple": false,
549
+ "char": "p",
550
+ "deprecateAliases": true,
551
+ "description": "The supplied paths can be a single file (in which case the operation is applied to only one file) or a folder (in which case the operation is applied to all metadata types in the directory and its sub-directories).\n\nIf you specify this flag, don’t specify --metadata.",
552
+ "name": "source-dir",
553
+ "summary": "Source file paths to delete.",
554
+ "delimiter": ",",
555
+ "hasDynamicHelp": false,
556
+ "multiple": true,
482
557
  "type": "option"
558
+ },
559
+ "track-source": {
560
+ "aliases": [
561
+ "tracksource"
562
+ ],
563
+ "char": "t",
564
+ "deprecateAliases": true,
565
+ "exclusive": [
566
+ "check-only"
567
+ ],
568
+ "name": "track-source",
569
+ "summary": "If the delete succeeds, update the source tracking information.",
570
+ "allowNo": false,
571
+ "type": "boolean"
572
+ },
573
+ "force-overwrite": {
574
+ "aliases": [
575
+ "forceoverwrite"
576
+ ],
577
+ "char": "f",
578
+ "dependsOn": [
579
+ "track-source"
580
+ ],
581
+ "deprecateAliases": true,
582
+ "name": "force-overwrite",
583
+ "summary": "Ignore conflict warnings and overwrite changes to the org.",
584
+ "allowNo": false,
585
+ "type": "boolean"
586
+ },
587
+ "verbose": {
588
+ "name": "verbose",
589
+ "summary": "Verbose output of the delete result.",
590
+ "allowNo": false,
591
+ "type": "boolean"
483
592
  }
484
593
  },
485
594
  "hasDynamicHelp": true,
486
595
  "hiddenAliases": [],
487
- "id": "project:deploy:cancel",
596
+ "id": "project:delete:source",
488
597
  "pluginAlias": "@salesforce/plugin-deploy-retrieve",
489
598
  "pluginName": "@salesforce/plugin-deploy-retrieve",
490
599
  "pluginType": "core",
491
600
  "strict": true,
492
- "summary": "Cancel a deploy operation.",
601
+ "summary": "Delete source from your project and from a non-source-tracked org.",
493
602
  "enableJsonFlag": true,
603
+ "requiresProject": true,
494
604
  "isESM": true,
495
605
  "relativePath": [
496
606
  "lib",
497
607
  "commands",
498
608
  "project",
499
- "deploy",
500
- "cancel.js"
609
+ "delete",
610
+ "source.js"
501
611
  ],
502
612
  "aliasPermutations": [
503
- "deploy:metadata:cancel",
504
- "metadata:deploy:cancel",
505
- "metadata:cancel:deploy",
506
- "deploy:cancel:metadata",
507
- "cancel:deploy:metadata",
508
- "cancel:metadata:deploy"
613
+ "force:source:delete",
614
+ "source:force:delete",
615
+ "source:delete:force",
616
+ "force:delete:source",
617
+ "delete:force:source",
618
+ "delete:source:force"
509
619
  ],
510
620
  "permutations": [
511
- "project:deploy:cancel",
512
- "deploy:project:cancel",
513
- "deploy:cancel:project",
514
- "project:cancel:deploy",
515
- "cancel:project:deploy",
516
- "cancel:deploy:project"
621
+ "project:delete:source",
622
+ "delete:project:source",
623
+ "delete:source:project",
624
+ "project:source:delete",
625
+ "source:project:delete",
626
+ "source:delete:project"
517
627
  ]
518
628
  },
519
- "project:deploy:preview": {
629
+ "project:delete:tracking": {
520
630
  "aliases": [
521
- "deploy:metadata:preview"
631
+ "force:source:tracking:clear"
522
632
  ],
523
633
  "args": {},
524
634
  "deprecateAliases": true,
525
- "description": "You must run this command from within a project.\n\nThe command outputs a table that describes what will happen if you run the \"<%= config.bin %> project deploy start\" command. The table lists the metadata components that will be deployed and deleted. The table also lists the current conflicts between files in your local project and components in the org. Finally, the table lists the files that won't be deployed because they're included in your .forceignore file.\n\nIf your org allows source tracking, then this command displays potential conflicts between the org and your local project. Some orgs, such as production org, never allow source tracking. Source tracking is enabled by default on scratch and sandbox orgs; you can disable source tracking when you create the orgs by specifying the --no-track-source flag on the \"<%= config.bin %> org create scratch|sandbox\" commands.\n\nTo preview the deployment of multiple metadata components, either set multiple --metadata <name> flags or a single --metadata flag with multiple names separated by spaces. Enclose names that contain spaces in one set of double quotes. The same syntax applies to --source-dir.",
635
+ "description": "WARNING: This command deletes or overwrites all existing source tracking files. Use with extreme caution.\n\nDeletes all local source tracking information. When you next run 'project deploy preview', Salesforce CLI displays all local and remote files as changed, and any files with the same name are listed as conflicts.",
526
636
  "examples": [
527
- "NOTE: The commands to preview a deployment and actually deploy it use similar flags. We provide a few preview examples here, but see the help for \"<%= config.bin %> project deploy start\" for more examples that you can adapt for previewing.",
528
- "Preview the deployment of source files in a directory, such as force-app, to your default org:\n<%= config.bin %> <%= command.id %> --source-dir force-app",
529
- "Preview the deployment of all Apex classes to an org with alias \"my-scratch\":\n<%= config.bin %> <%= command.id %> --metadata ApexClass --target-org my-scratch",
530
- "Preview deployment of a specific Apex class:\n<%= config.bin %> <%= command.id %> --metadata ApexClass:MyApexClass",
531
- "Preview deployment of all components listed in a manifest:\n<%= config.bin %> <%= command.id %> --manifest path/to/package.xml"
637
+ "Delete local source tracking for the org with alias \"my-scratch\":\n$ <%= config.bin %> <%= command.id %> --target-org my-scratch"
532
638
  ],
533
639
  "flags": {
534
640
  "json": {
@@ -546,54 +652,34 @@
546
652
  "multiple": false,
547
653
  "type": "option"
548
654
  },
549
- "ignore-conflicts": {
550
- "char": "c",
551
- "description": "This flag applies only to orgs that allow source tracking. It has no effect on orgs that don't allow it, such as production orgs.",
552
- "name": "ignore-conflicts",
553
- "summary": "Don't display conflicts in preview of the deployment.",
554
- "allowNo": false,
555
- "type": "boolean"
556
- },
557
- "manifest": {
558
- "char": "x",
559
- "description": "All child components are included. If you specify this flag, don’t specify --metadata or --source-dir.",
560
- "exclusive": [
561
- "source-dir",
562
- "metadata"
655
+ "api-version": {
656
+ "aliases": [
657
+ "apiversion"
563
658
  ],
564
- "name": "manifest",
565
- "summary": "Full file path for manifest (package.xml) of components to preview.",
659
+ "deprecateAliases": true,
660
+ "description": "Override the api version used for api requests made by this command",
661
+ "name": "api-version",
566
662
  "hasDynamicHelp": false,
567
663
  "multiple": false,
568
664
  "type": "option"
569
665
  },
570
- "metadata": {
571
- "char": "m",
572
- "exclusive": [
573
- "manifest",
574
- "source-dir"
575
- ],
576
- "name": "metadata",
577
- "summary": "Metadata component names to preview.",
666
+ "loglevel": {
667
+ "deprecated": {
668
+ "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."
669
+ },
670
+ "hidden": true,
671
+ "name": "loglevel",
578
672
  "hasDynamicHelp": false,
579
- "multiple": true,
580
- "type": "option"
581
- },
582
- "source-dir": {
583
- "char": "d",
584
- "description": "The supplied path can be to a single file (in which case the operation is applied to only one file) or to a folder (in which case the operation is applied to all metadata types in the directory and its subdirectories).\n\nIf you specify this flag, don’t specify --metadata or --manifest.",
585
- "exclusive": [
586
- "manifest",
587
- "metadata"
588
- ],
589
- "name": "source-dir",
590
- "summary": "Path to the local source files to preview.",
591
- "hasDynamicHelp": false,
592
- "multiple": true,
673
+ "multiple": false,
593
674
  "type": "option"
594
675
  },
595
676
  "target-org": {
677
+ "aliases": [
678
+ "targetusername",
679
+ "u"
680
+ ],
596
681
  "char": "o",
682
+ "deprecateAliases": true,
597
683
  "name": "target-org",
598
684
  "noCacheDefault": true,
599
685
  "required": true,
@@ -602,21 +688,26 @@
602
688
  "multiple": false,
603
689
  "type": "option"
604
690
  },
605
- "concise": {
606
- "name": "concise",
607
- "summary": "Show only the changes that will be deployed; omits files that are forceignored.",
691
+ "no-prompt": {
692
+ "aliases": [
693
+ "noprompt"
694
+ ],
695
+ "char": "p",
696
+ "deprecateAliases": true,
697
+ "name": "no-prompt",
698
+ "summary": "Don't prompt for source tracking override confirmation.",
608
699
  "allowNo": false,
609
700
  "type": "boolean"
610
701
  }
611
702
  },
612
703
  "hasDynamicHelp": true,
613
704
  "hiddenAliases": [],
614
- "id": "project:deploy:preview",
705
+ "id": "project:delete:tracking",
615
706
  "pluginAlias": "@salesforce/plugin-deploy-retrieve",
616
707
  "pluginName": "@salesforce/plugin-deploy-retrieve",
617
708
  "pluginType": "core",
618
709
  "strict": true,
619
- "summary": "Preview a deployment to see what will deploy to the org, the potential conflicts, and the ignored files.",
710
+ "summary": "Delete all local source tracking information.",
620
711
  "enableJsonFlag": true,
621
712
  "requiresProject": true,
622
713
  "isESM": true,
@@ -624,36 +715,54 @@
624
715
  "lib",
625
716
  "commands",
626
717
  "project",
627
- "deploy",
628
- "preview.js"
718
+ "delete",
719
+ "tracking.js"
629
720
  ],
630
721
  "aliasPermutations": [
631
- "deploy:metadata:preview",
632
- "metadata:deploy:preview",
633
- "metadata:preview:deploy",
634
- "deploy:preview:metadata",
635
- "preview:deploy:metadata",
636
- "preview:metadata:deploy"
722
+ "force:source:tracking:clear",
723
+ "source:force:tracking:clear",
724
+ "source:tracking:force:clear",
725
+ "source:tracking:clear:force",
726
+ "force:tracking:source:clear",
727
+ "tracking:force:source:clear",
728
+ "tracking:source:force:clear",
729
+ "tracking:source:clear:force",
730
+ "force:tracking:clear:source",
731
+ "tracking:force:clear:source",
732
+ "tracking:clear:force:source",
733
+ "tracking:clear:source:force",
734
+ "force:source:clear:tracking",
735
+ "source:force:clear:tracking",
736
+ "source:clear:force:tracking",
737
+ "source:clear:tracking:force",
738
+ "force:clear:source:tracking",
739
+ "clear:force:source:tracking",
740
+ "clear:source:force:tracking",
741
+ "clear:source:tracking:force",
742
+ "force:clear:tracking:source",
743
+ "clear:force:tracking:source",
744
+ "clear:tracking:force:source",
745
+ "clear:tracking:source:force"
637
746
  ],
638
747
  "permutations": [
639
- "project:deploy:preview",
640
- "deploy:project:preview",
641
- "deploy:preview:project",
642
- "project:preview:deploy",
643
- "preview:project:deploy",
644
- "preview:deploy:project"
748
+ "project:delete:tracking",
749
+ "delete:project:tracking",
750
+ "delete:tracking:project",
751
+ "project:tracking:delete",
752
+ "tracking:project:delete",
753
+ "tracking:delete:project"
645
754
  ]
646
755
  },
647
- "project:deploy:quick": {
756
+ "project:deploy:cancel": {
648
757
  "aliases": [
649
- "deploy:metadata:quick"
758
+ "deploy:metadata:cancel"
650
759
  ],
651
760
  "args": {},
652
761
  "deprecateAliases": true,
653
- "description": "Before you run this command, first create a validated deployment with the \"<%= config.bin %> project deploy validate\" command, which returns a job ID. Validated deployments haven't been deployed to the org yet; you deploy them with this command. Either pass the job ID to this command or use the --use-most-recent flag to use the job ID of the most recently validated deployment. For the quick deploy to succeed, the associated validated deployment must also have succeeded.\n\nExecuting this quick deploy command takes less time than a standard deploy because it skips running Apex tests. These tests were previously run as part of the validation. Validating first and then running a quick deploy is useful if the deployment to your production org take several hours and you don’t want to risk a failed deploy.\n\nThis command doesn't support source-tracking. The source you deploy overwrites the corresponding metadata in your org. This command doesn’t attempt to merge your source with the versions in your org.\n\nNote: Don't use this command on sandboxes; the command is intended to be used on production orgs. By default, sandboxes don't run tests during a deploy. Use \"<%= config.bin %> project deploy start\" instead.",
762
+ "description": "Use this command to cancel a deploy operation that hasn't yet completed in the org. Deploy operations include standard deploys, quick deploys, deploy validations, and deploy cancellations.\n\nRun this command by either passing it a job ID or specifying the --use-most-recent flag to use the job ID of the most recent deploy operation.",
654
763
  "examples": [
655
- "Run a quick deploy to your default org using a job ID:\n<%= config.bin %> <%= command.id %> --job-id 0Af0x000017yLUFCA2",
656
- "Asynchronously run a quick deploy of the most recently validated deployment to an org with alias \"my-prod-org\":\n<%= config.bin %> <%= command.id %> --async --use-most-recent --target-org my-prod-org"
764
+ "Cancel a deploy operation using a job ID:\n<%= config.bin %> <%= command.id %> --job-id 0Af0x000017yLUFCA2",
765
+ "Cancel the most recent deploy operation:\n<%= config.bin %> <%= command.id %> --use-most-recent"
657
766
  ],
658
767
  "flags": {
659
768
  "json": {
@@ -671,8 +780,17 @@
671
780
  "multiple": false,
672
781
  "type": "option"
673
782
  },
783
+ "target-org": {
784
+ "char": "o",
785
+ "name": "target-org",
786
+ "noCacheDefault": true,
787
+ "summary": "Username or alias of the target org.",
788
+ "hasDynamicHelp": true,
789
+ "multiple": false,
790
+ "type": "option"
791
+ },
674
792
  "async": {
675
- "description": "The command immediately returns the control of the terminal to you. This way, you can continue to use the CLI. To resume watching the deploy, run \"<%= config.bin %> project deploy resume\". To check the status of the deploy, run \"<%= config.bin %> project deploy report\".",
793
+ "description": "The command immediately returns the control of the terminal to you. This way, you can continue to use the CLI. To resume watching the cancellation, run \"<%= config.bin %> project deploy resume\". To check the status of the cancellation, run \"<%= config.bin %> project deploy report\".",
676
794
  "exclusive": [
677
795
  "wait"
678
796
  ],
@@ -681,152 +799,84 @@
681
799
  "allowNo": false,
682
800
  "type": "boolean"
683
801
  },
684
- "concise": {
685
- "exclusive": [
686
- "verbose"
687
- ],
688
- "name": "concise",
689
- "summary": "Show concise output of the deploy result.",
690
- "allowNo": false,
691
- "type": "boolean"
692
- },
693
802
  "job-id": {
694
803
  "char": "i",
695
- "description": "The job ID is valid for 10 days from when you started the validation.",
804
+ "description": "These commands return a job ID if they time out or you specified the --async flag:\n\n- <%= config.bin %> project deploy start\n- <%= config.bin %> project deploy validate\n- <%= config.bin %> project deploy quick\n- <%= config.bin %> project deploy cancel\n\nThe job ID is valid for 10 days from when you started the deploy operation.",
696
805
  "name": "job-id",
697
- "summary": "Job ID of the deployment you want to quick deploy.",
806
+ "summary": "Job ID of the deploy operation you want to cancel.",
698
807
  "hasDynamicHelp": false,
699
808
  "multiple": false,
700
809
  "type": "option"
701
810
  },
702
- "target-org": {
703
- "char": "o",
704
- "name": "target-org",
705
- "noCacheDefault": true,
706
- "summary": "Username or alias of the target org.",
707
- "hasDynamicHelp": true,
708
- "multiple": false,
709
- "type": "option"
710
- },
711
811
  "use-most-recent": {
712
812
  "char": "r",
713
- "description": "For performance reasons, this flag uses only job IDs that were validated in the past 3 days or less. If your most recent deployment validation was more than 3 days ago, this flag won't find a job ID.",
813
+ "description": "For performance reasons, this flag uses job IDs for deploy operations that started only in the past 3 days or less. If your most recent deploy operations was more than 3 days ago, this flag won't find a job ID.",
714
814
  "name": "use-most-recent",
715
- "summary": "Use the job ID of the most recently validated deployment.",
716
- "allowNo": false,
717
- "type": "boolean"
718
- },
719
- "verbose": {
720
- "exclusive": [
721
- "concise"
722
- ],
723
- "name": "verbose",
724
- "summary": "Show verbose output of the deploy result.",
815
+ "summary": "Use the job ID of the most recent deploy operation.",
725
816
  "allowNo": false,
726
817
  "type": "boolean"
727
818
  },
728
819
  "wait": {
729
820
  "char": "w",
730
- "description": "If the command continues to run after the wait period, the CLI returns control of the terminal window to you. To resume watching the deploy, run \"<%= config.bin %> project deploy resume\". To check the status of the deploy, run \"<%= config.bin %> project deploy report\".",
821
+ "description": "If the command continues to run after the wait period, the CLI returns control of the terminal window to you. To resume watching the cancellation, run \"<%= config.bin %> project deploy resume\". To check the status of the cancellation, run \"<%= config.bin %> project deploy report\".",
731
822
  "exclusive": [
732
823
  "async"
733
824
  ],
734
825
  "name": "wait",
735
826
  "summary": "Number of minutes to wait for the command to complete and display results.",
736
- "default": "33 minutes",
737
827
  "hasDynamicHelp": true,
738
828
  "helpValue": "<minutes>",
739
829
  "multiple": false,
740
830
  "type": "option"
741
- },
742
- "api-version": {
743
- "char": "a",
744
- "description": "Use this flag to override the default API version with the API version of your package.xml file. The default API version is the latest version supported by the CLI.",
745
- "name": "api-version",
746
- "summary": "Target API version for the deploy.",
747
- "hasDynamicHelp": false,
748
- "multiple": false,
749
- "type": "option"
750
831
  }
751
832
  },
752
833
  "hasDynamicHelp": true,
753
834
  "hiddenAliases": [],
754
- "id": "project:deploy:quick",
835
+ "id": "project:deploy:cancel",
755
836
  "pluginAlias": "@salesforce/plugin-deploy-retrieve",
756
837
  "pluginName": "@salesforce/plugin-deploy-retrieve",
757
838
  "pluginType": "core",
758
839
  "strict": true,
759
- "summary": "Quickly deploy a validated deployment to an org.",
840
+ "summary": "Cancel a deploy operation.",
760
841
  "enableJsonFlag": true,
761
- "errorCodes": {
762
- "header": "ERROR CODES",
763
- "body": [
764
- {
765
- "name": "Succeeded (0)",
766
- "description": "The deploy succeeded."
767
- },
768
- {
769
- "name": "Canceled (1)",
770
- "description": "The deploy was canceled."
771
- },
772
- {
773
- "name": "Failed (1)",
774
- "description": "The deploy failed."
775
- },
776
- {
777
- "name": "SucceededPartial (68)",
778
- "description": "The deploy partially succeeded."
779
- },
780
- {
781
- "name": "InProgress (69)",
782
- "description": "The deploy is in progress."
783
- },
784
- {
785
- "name": "Pending (69)",
786
- "description": "The deploy is pending."
787
- },
788
- {
789
- "name": "Canceling (69)",
790
- "description": "The deploy is being canceled."
791
- }
792
- ]
793
- },
794
842
  "isESM": true,
795
843
  "relativePath": [
796
844
  "lib",
797
845
  "commands",
798
846
  "project",
799
847
  "deploy",
800
- "quick.js"
848
+ "cancel.js"
801
849
  ],
802
850
  "aliasPermutations": [
803
- "deploy:metadata:quick",
804
- "metadata:deploy:quick",
805
- "metadata:quick:deploy",
806
- "deploy:quick:metadata",
807
- "quick:deploy:metadata",
808
- "quick:metadata:deploy"
851
+ "deploy:metadata:cancel",
852
+ "metadata:deploy:cancel",
853
+ "metadata:cancel:deploy",
854
+ "deploy:cancel:metadata",
855
+ "cancel:deploy:metadata",
856
+ "cancel:metadata:deploy"
809
857
  ],
810
858
  "permutations": [
811
- "project:deploy:quick",
812
- "deploy:project:quick",
813
- "deploy:quick:project",
814
- "project:quick:deploy",
815
- "quick:project:deploy",
816
- "quick:deploy:project"
859
+ "project:deploy:cancel",
860
+ "deploy:project:cancel",
861
+ "deploy:cancel:project",
862
+ "project:cancel:deploy",
863
+ "cancel:project:deploy",
864
+ "cancel:deploy:project"
817
865
  ]
818
866
  },
819
- "project:deploy:report": {
867
+ "project:deploy:preview": {
820
868
  "aliases": [
821
- "deploy:metadata:report"
869
+ "deploy:metadata:preview"
822
870
  ],
823
871
  "args": {},
824
872
  "deprecateAliases": true,
825
- "description": "Deploy operations include standard deploys, quick deploys, deploy validations, and deploy cancellations.\n\nRun this command by either passing it a job ID or specifying the --use-most-recent flag to use the job ID of the most recent deploy operation. If you specify the --wait flag, the command polls for the status every second until the timeout of --wait minutes. If you don't specify the --wait flag, the command simply checks and displays the status of the deploy; the command doesn't poll for the status.\n\nYou typically don't specify the --target-org flag because the cached job already references the org to which you deployed. But if you run this command on a computer different than the one from which you deployed, then you must specify the --target-org and it must point to the same org.\n\nThis command doesn't update source tracking information.",
873
+ "description": "You must run this command from within a project.\n\nThe command outputs a table that describes what will happen if you run the \"<%= config.bin %> project deploy start\" command. The table lists the metadata components that will be deployed and deleted. The table also lists the current conflicts between files in your local project and components in the org. Finally, the table lists the files that won't be deployed because they're included in your .forceignore file.\n\nIf your org allows source tracking, then this command displays potential conflicts between the org and your local project. Some orgs, such as production org, never allow source tracking. Source tracking is enabled by default on scratch and sandbox orgs; you can disable source tracking when you create the orgs by specifying the --no-track-source flag on the \"<%= config.bin %> org create scratch|sandbox\" commands.\n\nTo preview the deployment of multiple metadata components, either set multiple --metadata <name> flags or a single --metadata flag with multiple names separated by spaces. Enclose names that contain spaces in one set of double quotes. The same syntax applies to --source-dir.",
826
874
  "examples": [
827
- "Check the status using a job ID:\n<%= config.bin %> <%= command.id %> --job-id 0Af0x000017yLUFCA2",
828
- "Check the status of the most recent deploy operation:\n<%= config.bin %> <%= command.id %> --use-most-recent",
829
- "Poll for the status using a job ID and target org:\n<%= config.bin %> <%= command.id %> --job-id 0Af0x000017yLUFCA2 --target-org me@my.org --wait 30"
875
+ "NOTE: The commands to preview a deployment and actually deploy it use similar flags. We provide a few preview examples here, but see the help for \"<%= config.bin %> project deploy start\" for more examples that you can adapt for previewing.",
876
+ "Preview the deployment of source files in a directory, such as force-app, to your default org:\n<%= config.bin %> <%= command.id %> --source-dir force-app",
877
+ "Preview the deployment of all Apex classes to an org with alias \"my-scratch\":\n<%= config.bin %> <%= command.id %> --metadata ApexClass --target-org my-scratch",
878
+ "Preview deployment of a specific Apex class:\n<%= config.bin %> <%= command.id %> --metadata ApexClass:MyApexClass",
879
+ "Preview deployment of all components listed in a manifest:\n<%= config.bin %> <%= command.id %> --manifest path/to/package.xml"
830
880
  ],
831
881
  "flags": {
832
882
  "json": {
@@ -844,133 +894,114 @@
844
894
  "multiple": false,
845
895
  "type": "option"
846
896
  },
847
- "target-org": {
848
- "char": "o",
849
- "name": "target-org",
850
- "noCacheDefault": true,
851
- "summary": "Username or alias of the target org.",
852
- "hasDynamicHelp": true,
853
- "multiple": false,
854
- "type": "option"
897
+ "ignore-conflicts": {
898
+ "char": "c",
899
+ "description": "This flag applies only to orgs that allow source tracking. It has no effect on orgs that don't allow it, such as production orgs.",
900
+ "name": "ignore-conflicts",
901
+ "summary": "Don't display conflicts in preview of the deployment.",
902
+ "allowNo": false,
903
+ "type": "boolean"
855
904
  },
856
- "job-id": {
857
- "char": "i",
858
- "description": "These commands return a job ID if they time out or you specified the --async flag:\n\n- <%= config.bin %> project deploy start\n- <%= config.bin %> project deploy validate\n- <%= config.bin %> project deploy quick\n- <%= config.bin %> project deploy cancel\n\nThe job ID is valid for 10 days from when you started the deploy operation.",
859
- "name": "job-id",
860
- "summary": "Job ID of the deploy operation you want to check the status of.",
905
+ "manifest": {
906
+ "char": "x",
907
+ "description": "All child components are included. If you specify this flag, don’t specify --metadata or --source-dir.",
908
+ "exclusive": [
909
+ "source-dir",
910
+ "metadata"
911
+ ],
912
+ "name": "manifest",
913
+ "summary": "Full file path for manifest (package.xml) of components to preview.",
861
914
  "hasDynamicHelp": false,
862
915
  "multiple": false,
863
916
  "type": "option"
864
917
  },
865
- "use-most-recent": {
866
- "char": "r",
867
- "description": "For performance reasons, this flag uses job IDs for deploy operations that started only in the past 3 days or less. If your most recent operation was more than 3 days ago, this flag won't find a job ID.",
868
- "name": "use-most-recent",
869
- "summary": "Use the job ID of the most recent deploy operation.",
870
- "allowNo": false,
871
- "type": "boolean"
872
- },
873
- "coverage-formatters": {
874
- "description": "For multiple formatters, repeat the flag for each formatter.\n--coverage-formatters lcov --coverage-formatters clover",
875
- "helpGroup": "Test",
876
- "name": "coverage-formatters",
877
- "summary": "Format of the code coverage results.",
918
+ "metadata": {
919
+ "char": "m",
920
+ "exclusive": [
921
+ "manifest",
922
+ "source-dir"
923
+ ],
924
+ "name": "metadata",
925
+ "summary": "Metadata component names to preview.",
878
926
  "hasDynamicHelp": false,
879
927
  "multiple": true,
880
- "options": [
881
- "clover",
882
- "cobertura",
883
- "html-spa",
884
- "html",
885
- "json",
886
- "json-summary",
887
- "lcovonly",
888
- "none",
889
- "teamcity",
890
- "text",
891
- "text-summary"
892
- ],
893
928
  "type": "option"
894
929
  },
895
- "junit": {
896
- "helpGroup": "Test",
897
- "name": "junit",
898
- "summary": "Output JUnit test results.",
899
- "allowNo": false,
900
- "type": "boolean"
901
- },
902
- "results-dir": {
903
- "helpGroup": "Test",
904
- "name": "results-dir",
905
- "relationships": [
906
- {
907
- "type": "some",
908
- "flags": [
909
- "coverage-formatters",
910
- "junit"
911
- ]
912
- }
930
+ "source-dir": {
931
+ "char": "d",
932
+ "description": "The supplied path can be to a single file (in which case the operation is applied to only one file) or to a folder (in which case the operation is applied to all metadata types in the directory and its subdirectories).\n\nIf you specify this flag, don’t specify --metadata or --manifest.",
933
+ "exclusive": [
934
+ "manifest",
935
+ "metadata"
913
936
  ],
914
- "summary": "Output directory for code coverage and JUnit results; defaults to the deploy ID.",
937
+ "name": "source-dir",
938
+ "summary": "Path to the local source files to preview.",
915
939
  "hasDynamicHelp": false,
916
- "multiple": false,
940
+ "multiple": true,
917
941
  "type": "option"
918
942
  },
919
- "wait": {
920
- "char": "w",
921
- "description": "If the command continues to run after the wait period, the CLI returns control of the terminal window to you and returns the job ID. To resume the deployment, run \"<%= config.bin %> project deploy resume\". To check the status of the deployment, run \"<%= config.bin %> project deploy report\".",
922
- "name": "wait",
923
- "summary": "Number of minutes to wait for command to complete and display results.",
943
+ "target-org": {
944
+ "char": "o",
945
+ "name": "target-org",
946
+ "noCacheDefault": true,
947
+ "required": true,
948
+ "summary": "Username or alias of the target org. Not required if the `target-org` configuration variable is already set.",
924
949
  "hasDynamicHelp": true,
925
- "helpValue": "<minutes>",
926
950
  "multiple": false,
927
951
  "type": "option"
952
+ },
953
+ "concise": {
954
+ "name": "concise",
955
+ "summary": "Show only the changes that will be deployed; omits files that are forceignored.",
956
+ "allowNo": false,
957
+ "type": "boolean"
928
958
  }
929
959
  },
930
960
  "hasDynamicHelp": true,
931
961
  "hiddenAliases": [],
932
- "id": "project:deploy:report",
962
+ "id": "project:deploy:preview",
933
963
  "pluginAlias": "@salesforce/plugin-deploy-retrieve",
934
964
  "pluginName": "@salesforce/plugin-deploy-retrieve",
935
965
  "pluginType": "core",
936
966
  "strict": true,
937
- "summary": "Check or poll for the status of a deploy operation.",
967
+ "summary": "Preview a deployment to see what will deploy to the org, the potential conflicts, and the ignored files.",
938
968
  "enableJsonFlag": true,
969
+ "requiresProject": true,
939
970
  "isESM": true,
940
971
  "relativePath": [
941
972
  "lib",
942
973
  "commands",
943
974
  "project",
944
975
  "deploy",
945
- "report.js"
976
+ "preview.js"
946
977
  ],
947
978
  "aliasPermutations": [
948
- "deploy:metadata:report",
949
- "metadata:deploy:report",
950
- "metadata:report:deploy",
951
- "deploy:report:metadata",
952
- "report:deploy:metadata",
953
- "report:metadata:deploy"
979
+ "deploy:metadata:preview",
980
+ "metadata:deploy:preview",
981
+ "metadata:preview:deploy",
982
+ "deploy:preview:metadata",
983
+ "preview:deploy:metadata",
984
+ "preview:metadata:deploy"
954
985
  ],
955
986
  "permutations": [
956
- "project:deploy:report",
957
- "deploy:project:report",
958
- "deploy:report:project",
959
- "project:report:deploy",
960
- "report:project:deploy",
961
- "report:deploy:project"
987
+ "project:deploy:preview",
988
+ "deploy:project:preview",
989
+ "deploy:preview:project",
990
+ "project:preview:deploy",
991
+ "preview:project:deploy",
992
+ "preview:deploy:project"
962
993
  ]
963
994
  },
964
- "project:deploy:resume": {
995
+ "project:deploy:quick": {
965
996
  "aliases": [
966
- "deploy:metadata:resume"
997
+ "deploy:metadata:quick"
967
998
  ],
968
999
  "args": {},
969
1000
  "deprecateAliases": true,
970
- "description": "Use this command to resume watching a deploy operation if the original command times out or you specified the --async flag. Deploy operations include standard deploys, quick deploys, deploy validations, and deploy cancellations. This command doesn't resume the original operation itself, because the operation always continues after you've started it, regardless of whether you're watching it or not. When the deploy completes, source tracking information is updated as needed.\n\nRun this command by either passing it a job ID or specifying the --use-most-recent flag to use the job ID of the most recent deploy operation.",
1001
+ "description": "Before you run this command, first create a validated deployment with the \"<%= config.bin %> project deploy validate\" command, which returns a job ID. Validated deployments haven't been deployed to the org yet; you deploy them with this command. Either pass the job ID to this command or use the --use-most-recent flag to use the job ID of the most recently validated deployment. For the quick deploy to succeed, the associated validated deployment must also have succeeded.\n\nExecuting this quick deploy command takes less time than a standard deploy because it skips running Apex tests. These tests were previously run as part of the validation. Validating first and then running a quick deploy is useful if the deployment to your production org take several hours and you don’t want to risk a failed deploy.\n\nThis command doesn't support source-tracking. The source you deploy overwrites the corresponding metadata in your org. This command doesn’t attempt to merge your source with the versions in your org.\n\nNote: Don't use this command on sandboxes; the command is intended to be used on production orgs. By default, sandboxes don't run tests during a deploy. Use \"<%= config.bin %> project deploy start\" instead.",
971
1002
  "examples": [
972
- "Resume watching a deploy operation using a job ID:\n<%= config.bin %> <%= command.id %> --job-id 0Af0x000017yLUFCA2",
973
- "Resume watching the most recent deploy operation:\n<%= config.bin %> <%= command.id %> --use-most-recent"
1003
+ "Run a quick deploy to your default org using a job ID:\n<%= config.bin %> <%= command.id %> --job-id 0Af0x000017yLUFCA2",
1004
+ "Asynchronously run a quick deploy of the most recently validated deployment to an org with alias \"my-prod-org\":\n<%= config.bin %> <%= command.id %> --async --use-most-recent --target-org my-prod-org"
974
1005
  ],
975
1006
  "flags": {
976
1007
  "json": {
@@ -988,29 +1019,48 @@
988
1019
  "multiple": false,
989
1020
  "type": "option"
990
1021
  },
1022
+ "async": {
1023
+ "description": "The command immediately returns the control of the terminal to you. This way, you can continue to use the CLI. To resume watching the deploy, run \"<%= config.bin %> project deploy resume\". To check the status of the deploy, run \"<%= config.bin %> project deploy report\".",
1024
+ "exclusive": [
1025
+ "wait"
1026
+ ],
1027
+ "name": "async",
1028
+ "summary": "Run the command asynchronously.",
1029
+ "allowNo": false,
1030
+ "type": "boolean"
1031
+ },
991
1032
  "concise": {
992
1033
  "exclusive": [
993
1034
  "verbose"
994
1035
  ],
995
1036
  "name": "concise",
996
- "summary": "Show concise output of the deploy operation result.",
1037
+ "summary": "Show concise output of the deploy result.",
997
1038
  "allowNo": false,
998
1039
  "type": "boolean"
999
1040
  },
1000
1041
  "job-id": {
1001
1042
  "char": "i",
1002
- "description": "These commands return a job ID if they time out or you specified the --async flag:\n\n- <%= config.bin %> project deploy start\n- <%= config.bin %> project deploy validate\n- <%= config.bin %> project deploy quick\n- <%= config.bin %> project deploy cancel\n\nThe job ID is valid for 10 days from when you started the deploy operation.",
1043
+ "description": "The job ID is valid for 10 days from when you started the validation.",
1003
1044
  "name": "job-id",
1004
- "summary": "Job ID of the deploy operation you want to resume.",
1045
+ "summary": "Job ID of the deployment you want to quick deploy.",
1005
1046
  "hasDynamicHelp": false,
1006
1047
  "multiple": false,
1007
1048
  "type": "option"
1008
1049
  },
1050
+ "target-org": {
1051
+ "char": "o",
1052
+ "name": "target-org",
1053
+ "noCacheDefault": true,
1054
+ "summary": "Username or alias of the target org.",
1055
+ "hasDynamicHelp": true,
1056
+ "multiple": false,
1057
+ "type": "option"
1058
+ },
1009
1059
  "use-most-recent": {
1010
1060
  "char": "r",
1011
- "description": "For performance reasons, this flag uses job IDs for deploy operations that started only in the past 3 days or less. If your most recent operation was more than 3 days ago, this flag won't find a job ID.",
1061
+ "description": "For performance reasons, this flag uses only job IDs that were validated in the past 3 days or less. If your most recent deployment validation was more than 3 days ago, this flag won't find a job ID.",
1012
1062
  "name": "use-most-recent",
1013
- "summary": "Use the job ID of the most recent deploy operation.",
1063
+ "summary": "Use the job ID of the most recently validated deployment.",
1014
1064
  "allowNo": false,
1015
1065
  "type": "boolean"
1016
1066
  },
@@ -1019,62 +1069,29 @@
1019
1069
  "concise"
1020
1070
  ],
1021
1071
  "name": "verbose",
1022
- "summary": "Show verbose output of the deploy operation result.",
1072
+ "summary": "Show verbose output of the deploy result.",
1023
1073
  "allowNo": false,
1024
1074
  "type": "boolean"
1025
1075
  },
1026
1076
  "wait": {
1027
1077
  "char": "w",
1028
- "description": "If the command continues to run after the wait period, the CLI returns control of the terminal window to you. To resume watching the deploy operation, run this command again. To check the status of the deploy operation, run \"<%= config.bin %> project deploy report\".",
1078
+ "description": "If the command continues to run after the wait period, the CLI returns control of the terminal window to you. To resume watching the deploy, run \"<%= config.bin %> project deploy resume\". To check the status of the deploy, run \"<%= config.bin %> project deploy report\".",
1079
+ "exclusive": [
1080
+ "async"
1081
+ ],
1029
1082
  "name": "wait",
1030
1083
  "summary": "Number of minutes to wait for the command to complete and display results.",
1084
+ "default": "33 minutes",
1031
1085
  "hasDynamicHelp": true,
1032
1086
  "helpValue": "<minutes>",
1033
1087
  "multiple": false,
1034
1088
  "type": "option"
1035
1089
  },
1036
- "coverage-formatters": {
1037
- "description": "For multiple formatters, repeat the flag for each formatter.\n--coverage-formatters lcov --coverage-formatters clover",
1038
- "helpGroup": "Test",
1039
- "name": "coverage-formatters",
1040
- "summary": "Format of the code coverage results.",
1041
- "hasDynamicHelp": false,
1042
- "multiple": true,
1043
- "options": [
1044
- "clover",
1045
- "cobertura",
1046
- "html-spa",
1047
- "html",
1048
- "json",
1049
- "json-summary",
1050
- "lcovonly",
1051
- "none",
1052
- "teamcity",
1053
- "text",
1054
- "text-summary"
1055
- ],
1056
- "type": "option"
1057
- },
1058
- "junit": {
1059
- "helpGroup": "Test",
1060
- "name": "junit",
1061
- "summary": "Output JUnit test results.",
1062
- "allowNo": false,
1063
- "type": "boolean"
1064
- },
1065
- "results-dir": {
1066
- "helpGroup": "Test",
1067
- "name": "results-dir",
1068
- "relationships": [
1069
- {
1070
- "type": "some",
1071
- "flags": [
1072
- "coverage-formatters",
1073
- "junit"
1074
- ]
1075
- }
1076
- ],
1077
- "summary": "Output directory for code coverage and JUnit results; defaults to the deploy ID.",
1090
+ "api-version": {
1091
+ "char": "a",
1092
+ "description": "Use this flag to override the default API version with the API version of your package.xml file. The default API version is the latest version supported by the CLI.",
1093
+ "name": "api-version",
1094
+ "summary": "Target API version for the deploy.",
1078
1095
  "hasDynamicHelp": false,
1079
1096
  "multiple": false,
1080
1097
  "type": "option"
@@ -1082,22 +1099,13 @@
1082
1099
  },
1083
1100
  "hasDynamicHelp": true,
1084
1101
  "hiddenAliases": [],
1085
- "id": "project:deploy:resume",
1102
+ "id": "project:deploy:quick",
1086
1103
  "pluginAlias": "@salesforce/plugin-deploy-retrieve",
1087
1104
  "pluginName": "@salesforce/plugin-deploy-retrieve",
1088
1105
  "pluginType": "core",
1089
1106
  "strict": true,
1090
- "summary": "Resume watching a deploy operation and update source tracking when the deploy completes.",
1107
+ "summary": "Quickly deploy a validated deployment to an org.",
1091
1108
  "enableJsonFlag": true,
1092
- "envVariablesSection": {
1093
- "header": "ENVIRONMENT VARIABLES",
1094
- "body": [
1095
- {
1096
- "name": "SF_USE_PROGRESS_BAR",
1097
- "description": "Set to false to disable the progress bar when running the metadata deploy command."
1098
- }
1099
- ]
1100
- },
1101
1109
  "errorCodes": {
1102
1110
  "header": "ERROR CODES",
1103
1111
  "body": [
@@ -1137,47 +1145,36 @@
1137
1145
  "commands",
1138
1146
  "project",
1139
1147
  "deploy",
1140
- "resume.js"
1148
+ "quick.js"
1141
1149
  ],
1142
1150
  "aliasPermutations": [
1143
- "deploy:metadata:resume",
1144
- "metadata:deploy:resume",
1145
- "metadata:resume:deploy",
1146
- "deploy:resume:metadata",
1147
- "resume:deploy:metadata",
1148
- "resume:metadata:deploy"
1151
+ "deploy:metadata:quick",
1152
+ "metadata:deploy:quick",
1153
+ "metadata:quick:deploy",
1154
+ "deploy:quick:metadata",
1155
+ "quick:deploy:metadata",
1156
+ "quick:metadata:deploy"
1149
1157
  ],
1150
1158
  "permutations": [
1151
- "project:deploy:resume",
1152
- "deploy:project:resume",
1153
- "deploy:resume:project",
1154
- "project:resume:deploy",
1155
- "resume:project:deploy",
1156
- "resume:deploy:project"
1159
+ "project:deploy:quick",
1160
+ "deploy:project:quick",
1161
+ "deploy:quick:project",
1162
+ "project:quick:deploy",
1163
+ "quick:project:deploy",
1164
+ "quick:deploy:project"
1157
1165
  ]
1158
1166
  },
1159
- "project:deploy:start": {
1167
+ "project:deploy:report": {
1160
1168
  "aliases": [
1161
- "deploy:metadata"
1169
+ "deploy:metadata:report"
1162
1170
  ],
1163
1171
  "args": {},
1164
1172
  "deprecateAliases": true,
1165
- "description": "You must run this command from within a project.\n\nMetadata components are deployed in source format by default. Deploy them in metadata format by specifying the --metadata-dir flag, which specifies the root directory or ZIP file that contains the metadata formatted files you want to deploy.\n\nIf your org allows source tracking, then this command tracks the changes in your source. Some orgs, such as production orgs, never allow source tracking. Source tracking is enabled by default on scratch and sandbox orgs; you can disable source tracking when you create the orgs by specifying the --no-track-source flag on the \"<%= config.bin %> org create scratch|sandbox\" commands.\n\nTo deploy multiple metadata components, either set multiple --metadata <name> flags or a single --metadata flag with multiple names separated by spaces. Enclose names that contain spaces in one set of double quotes. The same syntax applies to --source-dir.",
1173
+ "description": "Deploy operations include standard deploys, quick deploys, deploy validations, and deploy cancellations.\n\nRun this command by either passing it a job ID or specifying the --use-most-recent flag to use the job ID of the most recent deploy operation. If you specify the --wait flag, the command polls for the status every second until the timeout of --wait minutes. If you don't specify the --wait flag, the command simply checks and displays the status of the deploy; the command doesn't poll for the status.\n\nYou typically don't specify the --target-org flag because the cached job already references the org to which you deployed. But if you run this command on a computer different than the one from which you deployed, then you must specify the --target-org and it must point to the same org.\n\nThis command doesn't update source tracking information.",
1166
1174
  "examples": [
1167
- "Deploy local changes not in the org; uses your default org:\n<%= config.bin %> <%= command.id %>",
1168
- "Deploy all source files in the \"force-app\" directory to an org with alias \"my-scratch\"; show only concise output, in other words don't print a list of all the source that was deployed:\n<%= config.bin %> <%= command.id %> --source-dir force-app --target-org my-scratch --concise",
1169
- "Deploy all the Apex classes and custom objects that are in the \"force-app\" directory. The list views, layouts, etc, that are associated with the custom objects are also deployed. Both examples are equivalent:\n<%= config.bin %> <%= command.id %> --source-dir force-app/main/default/classes force-app/main/default/objects\n<%= config.bin %> <%= command.id %> --source-dir force-app/main/default/classes --source-dir force-app/main/default/objects",
1170
- "Deploy all Apex classes that are in all package directories defined in the \"sfdx-project.json\" file:\n<%= config.bin %> <%= command.id %> --metadata ApexClass",
1171
- "Deploy a specific Apex class; ignore any conflicts between the local project and org (be careful with this flag, because it will overwrite the Apex class in the org if there are conflicts!):\n<%= config.bin %> <%= command.id %> --metadata ApexClass:MyApexClass --ignore-conflicts",
1172
- "Deploy specific Apex classes that match a pattern; in this example, deploy Apex classes whose names contain the string \"MyApex\". Also ignore any deployment warnings (again, be careful with this flag! You typically want to see the warnings):\n<%= config.bin %> <%= command.id %> --metadata 'ApexClass:MyApex*' --ignore-warnings",
1173
- "Deploy a custom object called ExcitingObject that's in the SBQQ namespace:\nsf <%= command.id %> --metadata CustomObject:SBQQ__ExcitingObject",
1174
- "Deploy all custom objects in the SBQQ namespace by using a wildcard and quotes:\nsf <%= command.id %> --metadata 'CustomObject:SBQQ__*'",
1175
- "Deploy all custom objects and Apex classes found in all defined package directories (both examples are equivalent):\n<%= config.bin %> <%= command.id %> --metadata CustomObject ApexClass\n<%= config.bin %> <%= command.id %> --metadata CustomObject --metadata ApexClass",
1176
- "Deploy all Apex classes and a profile that has a space in its name:\n<%= config.bin %> <%= command.id %> --metadata ApexClass --metadata \"Profile:My Profile\"",
1177
- "Deploy all components listed in a manifest:\n<%= config.bin %> <%= command.id %> --manifest path/to/package.xml",
1178
- "Run the tests that aren’t in any managed packages as part of a deployment:\n<%= config.bin %> <%= command.id %> --metadata ApexClass --test-level RunLocalTests",
1179
- "Deploy all metadata formatted files in the \"MDAPI\" directory:\n<%= config.bin %> <%= command.id %> --metadata-dir MDAPI",
1180
- "Deploy all metadata formatted files in the \"MDAPI\" directory; items listed in the MDAPI/destructiveChangesPre.xml and MDAPI/destructiveChangesPost.xml manifests are immediately eligible for deletion rather than stored in the Recycle Bin:\n<%= config.bin %> <%= command.id %> --metadata-dir MDAPI --purge-on-delete"
1175
+ "Check the status using a job ID:\n<%= config.bin %> <%= command.id %> --job-id 0Af0x000017yLUFCA2",
1176
+ "Check the status of the most recent deploy operation:\n<%= config.bin %> <%= command.id %> --use-most-recent",
1177
+ "Poll for the status using a job ID and target org:\n<%= config.bin %> <%= command.id %> --job-id 0Af0x000017yLUFCA2 --target-org me@my.org --wait 30"
1181
1178
  ],
1182
1179
  "flags": {
1183
1180
  "json": {
@@ -1195,230 +1192,32 @@
1195
1192
  "multiple": false,
1196
1193
  "type": "option"
1197
1194
  },
1198
- "api-version": {
1199
- "char": "a",
1200
- "description": "Use this flag to override the default API version with the API version of your package.xml file. The default API version is the latest version supported by the CLI.",
1201
- "name": "api-version",
1202
- "summary": "Target API version for the deploy.",
1203
- "hasDynamicHelp": false,
1204
- "multiple": false,
1205
- "type": "option"
1206
- },
1207
- "async": {
1208
- "description": "The command immediately returns the job ID and control of the terminal to you. This way, you can continue to use the CLI. To resume the deployment, run \"<%= config.bin %> project deploy resume\". To check the status of the deployment, run \"<%= config.bin %> project deploy report\".",
1209
- "exclusive": [
1210
- "wait"
1211
- ],
1212
- "name": "async",
1213
- "summary": "Run the command asynchronously.",
1214
- "allowNo": false,
1215
- "type": "boolean"
1216
- },
1217
- "concise": {
1218
- "exclusive": [
1219
- "verbose"
1220
- ],
1221
- "name": "concise",
1222
- "summary": "Show concise output of the deploy result.",
1223
- "allowNo": false,
1224
- "type": "boolean"
1225
- },
1226
- "dry-run": {
1227
- "name": "dry-run",
1228
- "summary": "Validate deploy and run Apex tests but don’t save to the org.",
1229
- "allowNo": false,
1230
- "type": "boolean"
1231
- },
1232
- "ignore-conflicts": {
1233
- "char": "c",
1234
- "description": "This flag applies only to orgs that allow source tracking. It has no effect on orgs that don't allow it, such as production orgs.",
1235
- "name": "ignore-conflicts",
1236
- "summary": "Ignore conflicts and deploy local files, even if they overwrite changes in the org.",
1237
- "allowNo": false,
1238
- "type": "boolean"
1239
- },
1240
- "ignore-errors": {
1241
- "char": "r",
1242
- "description": "Never use this flag when deploying to a production org. If you specify it, components without errors are deployed and components with errors are skipped, and could result in an inconsistent production org.",
1243
- "name": "ignore-errors",
1244
- "summary": "Ignore any errors and don’t roll back deployment.",
1245
- "allowNo": false,
1246
- "type": "boolean"
1247
- },
1248
- "ignore-warnings": {
1249
- "char": "g",
1250
- "description": "If you specify this flag, and a warning occurs, the success status of the deployment is set to true. If you don't specify this flag, and a warning occurs, then the success status is set to false, and the warning is treated like an error.\n\nThis flag is useful in a CI environment and your deployment includes destructive changes; if you try to delete a component that doesn't exist in the org, you get a warning. In this case, to ensure that the command returns a success value of true, specify this flag.",
1251
- "name": "ignore-warnings",
1252
- "summary": "Ignore warnings and allow a deployment to complete successfully.",
1253
- "allowNo": false,
1254
- "type": "boolean"
1255
- },
1256
- "manifest": {
1257
- "char": "x",
1258
- "description": "All child components are included. If you specify this flag, don’t specify --metadata or --source-dir.",
1259
- "exclusive": [
1260
- "source-dir",
1261
- "metadata",
1262
- "metadata-dir"
1263
- ],
1264
- "helpGroup": "Source Format",
1265
- "name": "manifest",
1266
- "summary": "Full file path for manifest (package.xml) of components to deploy.",
1267
- "hasDynamicHelp": false,
1268
- "multiple": false,
1269
- "type": "option"
1270
- },
1271
- "metadata": {
1272
- "char": "m",
1273
- "exclusive": [
1274
- "manifest",
1275
- "source-dir",
1276
- "metadata-dir"
1277
- ],
1278
- "helpGroup": "Source Format",
1279
- "name": "metadata",
1280
- "summary": "Metadata component names to deploy. Wildcards (`*` ) supported as long as you use quotes, such as `ApexClass:MyClass*`.",
1281
- "hasDynamicHelp": false,
1282
- "multiple": true,
1283
- "type": "option"
1284
- },
1285
- "metadata-dir": {
1286
- "exclusive": [
1287
- "manifest",
1288
- "source-dir",
1289
- "metadata"
1290
- ],
1291
- "helpGroup": "Metadata API Format",
1292
- "name": "metadata-dir",
1293
- "summary": "Root of directory or zip file of metadata formatted files to deploy.",
1294
- "hasDynamicHelp": false,
1295
- "multiple": false,
1296
- "type": "option"
1297
- },
1298
- "single-package": {
1299
- "dependsOn": [
1300
- "metadata-dir"
1301
- ],
1302
- "helpGroup": "Metadata API Format",
1303
- "name": "single-package",
1304
- "summary": "Indicates that the metadata zip file points to a directory structure for a single package.",
1305
- "allowNo": false,
1306
- "type": "boolean"
1307
- },
1308
- "source-dir": {
1309
- "char": "d",
1310
- "description": "The supplied path can be to a single file (in which case the operation is applied to only one file) or to a folder (in which case the operation is applied to all metadata types in the directory and its subdirectories).\n\nIf you specify this flag, don’t specify --metadata or --manifest.",
1311
- "exclusive": [
1312
- "manifest",
1313
- "metadata",
1314
- "metadata-dir"
1315
- ],
1316
- "helpGroup": "Source Format",
1317
- "name": "source-dir",
1318
- "summary": "Path to the local source files to deploy.",
1319
- "hasDynamicHelp": false,
1320
- "multiple": true,
1321
- "type": "option"
1322
- },
1323
1195
  "target-org": {
1324
1196
  "char": "o",
1325
1197
  "name": "target-org",
1326
1198
  "noCacheDefault": true,
1327
- "required": true,
1328
- "summary": "Username or alias of the target org. Not required if the `target-org` configuration variable is already set.",
1199
+ "summary": "Username or alias of the target org.",
1329
1200
  "hasDynamicHelp": true,
1330
1201
  "multiple": false,
1331
1202
  "type": "option"
1332
1203
  },
1333
- "tests": {
1334
- "char": "t",
1335
- "description": "If a test name contains a space, enclose it in double quotes.\nFor multiple test names, use one of the following formats:\n\n- Repeat the flag for multiple test names: --tests Test1 --tests Test2 --tests \"Test With Space\"\n- Separate the test names with spaces: --tests Test1 Test2 \"Test With Space\"",
1336
- "helpGroup": "Test",
1337
- "name": "tests",
1338
- "summary": "Apex tests to run when --test-level is RunSpecifiedTests.",
1339
- "hasDynamicHelp": false,
1340
- "multiple": true,
1341
- "type": "option"
1342
- },
1343
- "test-level": {
1344
- "char": "l",
1345
- "description": "Valid values are:\n\n- NoTestRun — No tests are run. This test level applies only to deployments to development environments, such as sandbox, Developer Edition, or trial orgs. This test level is the default for development environments.\n\n- RunSpecifiedTests — Runs only the tests that you specify with the --tests flag. Code coverage requirements differ from the default coverage requirements when using this test level. Executed tests must comprise a minimum of 75% code coverage for each class and trigger in the deployment package. This coverage is computed for each class and trigger individually and is different than the overall coverage percentage.\n\n- RunLocalTests — All tests in your org are run, except the ones that originate from installed managed and unlocked packages. This test level is the default for production deployments that include Apex classes or triggers.\n\n- RunAllTestsInOrg — All tests in your org are run, including tests of managed packages.\n\n- RunRelevantTests — Runs only tests that are relevant to the files being deployed.\n\n If you don’t specify a test level, the default behavior depends on the contents of your deployment package and target org. For more information, see [Running Tests in a Deployment](https://developer.salesforce.com/docs/atlas.en-us.api_meta.meta/api_meta/meta_deploy_running_tests.htm) in the \"Metadata API Developer Guide\".",
1346
- "helpGroup": "Test",
1347
- "name": "test-level",
1348
- "summary": "Deployment Apex testing level.",
1204
+ "job-id": {
1205
+ "char": "i",
1206
+ "description": "These commands return a job ID if they time out or you specified the --async flag:\n\n- <%= config.bin %> project deploy start\n- <%= config.bin %> project deploy validate\n- <%= config.bin %> project deploy quick\n- <%= config.bin %> project deploy cancel\n\nThe job ID is valid for 10 days from when you started the deploy operation.",
1207
+ "name": "job-id",
1208
+ "summary": "Job ID of the deploy operation you want to check the status of.",
1349
1209
  "hasDynamicHelp": false,
1350
1210
  "multiple": false,
1351
- "options": [
1352
- "NoTestRun",
1353
- "RunSpecifiedTests",
1354
- "RunLocalTests",
1355
- "RunAllTestsInOrg",
1356
- "RunRelevantTests"
1357
- ],
1358
- "type": "option"
1359
- },
1360
- "verbose": {
1361
- "exclusive": [
1362
- "concise"
1363
- ],
1364
- "name": "verbose",
1365
- "summary": "Show verbose output of the deploy result.",
1366
- "allowNo": false,
1367
- "type": "boolean"
1368
- },
1369
- "wait": {
1370
- "char": "w",
1371
- "description": "If the command continues to run after the wait period, the CLI returns control of the terminal window to you and returns the job ID. To resume the deployment, run \"<%= config.bin %> project deploy resume\". To check the status of the deployment, run \"<%= config.bin %> project deploy report\".",
1372
- "exclusive": [
1373
- "async"
1374
- ],
1375
- "name": "wait",
1376
- "summary": "Number of minutes to wait for command to complete and display results.",
1377
- "hasDynamicHelp": true,
1378
- "helpValue": "<minutes>",
1379
- "multiple": false,
1380
1211
  "type": "option"
1381
1212
  },
1382
- "purge-on-delete": {
1383
- "helpGroup": "Delete",
1384
- "name": "purge-on-delete",
1385
- "relationships": [
1386
- {
1387
- "type": "some",
1388
- "flags": [
1389
- "pre-destructive-changes",
1390
- "manifest",
1391
- "metadata-dir",
1392
- "post-destructive-changes"
1393
- ]
1394
- }
1395
- ],
1396
- "summary": "Specify that deleted components in the destructive changes manifest file are immediately eligible for deletion rather than being stored in the Recycle Bin.",
1213
+ "use-most-recent": {
1214
+ "char": "r",
1215
+ "description": "For performance reasons, this flag uses job IDs for deploy operations that started only in the past 3 days or less. If your most recent operation was more than 3 days ago, this flag won't find a job ID.",
1216
+ "name": "use-most-recent",
1217
+ "summary": "Use the job ID of the most recent deploy operation.",
1397
1218
  "allowNo": false,
1398
1219
  "type": "boolean"
1399
1220
  },
1400
- "pre-destructive-changes": {
1401
- "dependsOn": [
1402
- "manifest"
1403
- ],
1404
- "helpGroup": "Delete",
1405
- "name": "pre-destructive-changes",
1406
- "summary": "File path for a manifest (destructiveChangesPre.xml) of components to delete before the deploy.",
1407
- "hasDynamicHelp": false,
1408
- "multiple": false,
1409
- "type": "option"
1410
- },
1411
- "post-destructive-changes": {
1412
- "dependsOn": [
1413
- "manifest"
1414
- ],
1415
- "helpGroup": "Delete",
1416
- "name": "post-destructive-changes",
1417
- "summary": "File path for a manifest (destructiveChangesPost.xml) of components to delete after the deploy.",
1418
- "hasDynamicHelp": false,
1419
- "multiple": false,
1420
- "type": "option"
1421
- },
1422
1221
  "coverage-formatters": {
1423
1222
  "description": "For multiple formatters, repeat the flag for each formatter.\n--coverage-formatters lcov --coverage-formatters clover",
1424
1223
  "helpGroup": "Test",
@@ -1464,110 +1263,62 @@
1464
1263
  "hasDynamicHelp": false,
1465
1264
  "multiple": false,
1466
1265
  "type": "option"
1266
+ },
1267
+ "wait": {
1268
+ "char": "w",
1269
+ "description": "If the command continues to run after the wait period, the CLI returns control of the terminal window to you and returns the job ID. To resume the deployment, run \"<%= config.bin %> project deploy resume\". To check the status of the deployment, run \"<%= config.bin %> project deploy report\".",
1270
+ "name": "wait",
1271
+ "summary": "Number of minutes to wait for command to complete and display results.",
1272
+ "hasDynamicHelp": true,
1273
+ "helpValue": "<minutes>",
1274
+ "multiple": false,
1275
+ "type": "option"
1467
1276
  }
1468
1277
  },
1469
1278
  "hasDynamicHelp": true,
1470
1279
  "hiddenAliases": [],
1471
- "id": "project:deploy:start",
1280
+ "id": "project:deploy:report",
1472
1281
  "pluginAlias": "@salesforce/plugin-deploy-retrieve",
1473
1282
  "pluginName": "@salesforce/plugin-deploy-retrieve",
1474
1283
  "pluginType": "core",
1475
1284
  "strict": true,
1476
- "summary": "Deploy metadata to an org from your local project.",
1285
+ "summary": "Check or poll for the status of a deploy operation.",
1477
1286
  "enableJsonFlag": true,
1478
- "configurationVariablesSection": {
1479
- "header": "CONFIGURATION VARIABLES",
1480
- "body": [
1481
- {
1482
- "name": "target-org",
1483
- "description": "Username or alias of the org that all commands run against by default. (sf only)"
1484
- },
1485
- {
1486
- "name": "org-api-version",
1487
- "description": "API version of your project. Default: API version of your Dev Hub org."
1488
- }
1489
- ]
1490
- },
1491
- "envVariablesSection": {
1492
- "header": "ENVIRONMENT VARIABLES",
1493
- "body": [
1494
- {
1495
- "name": "SF_TARGET_ORG",
1496
- "description": "Username or alias of your default org. Overrides the target-org configuration variable."
1497
- },
1498
- {
1499
- "name": "SF_USE_PROGRESS_BAR",
1500
- "description": "Set to false to disable the progress bar when running the metadata deploy command."
1501
- }
1502
- ]
1503
- },
1504
- "errorCodes": {
1505
- "header": "ERROR CODES",
1506
- "body": [
1507
- {
1508
- "name": "Succeeded (0)",
1509
- "description": "The deploy succeeded."
1510
- },
1511
- {
1512
- "name": "Canceled (1)",
1513
- "description": "The deploy was canceled."
1514
- },
1515
- {
1516
- "name": "Failed (1)",
1517
- "description": "The deploy failed."
1518
- },
1519
- {
1520
- "name": "SucceededPartial (68)",
1521
- "description": "The deploy partially succeeded."
1522
- },
1523
- {
1524
- "name": "InProgress (69)",
1525
- "description": "The deploy is in progress."
1526
- },
1527
- {
1528
- "name": "Pending (69)",
1529
- "description": "The deploy is pending."
1530
- },
1531
- {
1532
- "name": "Canceling (69)",
1533
- "description": "The deploy is being canceled."
1534
- }
1535
- ]
1536
- },
1537
1287
  "isESM": true,
1538
1288
  "relativePath": [
1539
1289
  "lib",
1540
1290
  "commands",
1541
1291
  "project",
1542
1292
  "deploy",
1543
- "start.js"
1293
+ "report.js"
1544
1294
  ],
1545
1295
  "aliasPermutations": [
1546
- "deploy:metadata",
1547
- "metadata:deploy"
1296
+ "deploy:metadata:report",
1297
+ "metadata:deploy:report",
1298
+ "metadata:report:deploy",
1299
+ "deploy:report:metadata",
1300
+ "report:deploy:metadata",
1301
+ "report:metadata:deploy"
1548
1302
  ],
1549
1303
  "permutations": [
1550
- "project:deploy:start",
1551
- "deploy:project:start",
1552
- "deploy:start:project",
1553
- "project:start:deploy",
1554
- "start:project:deploy",
1555
- "start:deploy:project"
1304
+ "project:deploy:report",
1305
+ "deploy:project:report",
1306
+ "deploy:report:project",
1307
+ "project:report:deploy",
1308
+ "report:project:deploy",
1309
+ "report:deploy:project"
1556
1310
  ]
1557
1311
  },
1558
- "project:deploy:validate": {
1312
+ "project:deploy:resume": {
1559
1313
  "aliases": [
1560
- "deploy:metadata:validate"
1314
+ "deploy:metadata:resume"
1561
1315
  ],
1562
1316
  "args": {},
1563
1317
  "deprecateAliases": true,
1564
- "description": "Use this command to verify whether a deployment will succeed without actually deploying the metadata to your org. This command is similar to \"<%= config.bin %> project deploy start\", except you're required to run Apex tests, and the command returns a job ID rather than executing the deployment. If the validation succeeds, then you pass this job ID to the \"<%= config.bin %> project deploy quick\" command to actually deploy the metadata. This quick deploy takes less time because it skips running Apex tests. The job ID is valid for 10 days from when you started the validation. Validating first is useful if the deployment to your production org take several hours and you don’t want to risk a failed deploy.\n\nYou must run this command from within a project.\n\nThis command doesn't support source-tracking. When you quick deploy with the resulting job ID, the source you deploy overwrites the corresponding metadata in your org.\n\nTo validate the deployment of multiple metadata components, either set multiple --metadata <name> flags or a single --metadata flag with multiple names separated by spaces. Enclose names that contain spaces in one set of double quotes. The same syntax applies to --source-dir.\n\nNote: Don't use this command on sandboxes; the command is intended to be used on production orgs. By default, sandboxes don't run tests during a deploy. If you want to validate a deployment with tests on a sandbox, use \"<%= config.bin %> project deploy start --dry-run --test-level RunLocalTests\" instead.",
1318
+ "description": "Use this command to resume watching a deploy operation if the original command times out or you specified the --async flag. Deploy operations include standard deploys, quick deploys, deploy validations, and deploy cancellations. This command doesn't resume the original operation itself, because the operation always continues after you've started it, regardless of whether you're watching it or not. When the deploy completes, source tracking information is updated as needed.\n\nRun this command by either passing it a job ID or specifying the --use-most-recent flag to use the job ID of the most recent deploy operation.",
1565
1319
  "examples": [
1566
- "NOTE: These examples focus on validating large deployments. See the help for \"<%= config.bin %> project deploy start\" for examples of deploying smaller sets of metadata which you can also use to validate.",
1567
- "Validate the deployment of all source files in the \"force-app\" directory to the default org:\n<%= config.bin %> <%= command.id %> --source-dir force-app",
1568
- "Validate the deployment of all source files in two directories: \"force-app\" and \"force-app-utils\":\n<%= config.bin %> <%= command.id %> --source-dir force-app --source-dir force-app-utils",
1569
- "Asynchronously validate the deployment and run all tests in the org with alias \"my-prod-org\"; command immediately returns the job ID:\n<%= config.bin %> <%= command.id %> --source-dir force-app --async --test-level RunAllTestsInOrg --target-org my-prod-org",
1570
- "Validate the deployment of all components listed in a manifest:\n<%= config.bin %> <%= command.id %> --manifest path/to/package.xml"
1320
+ "Resume watching a deploy operation using a job ID:\n<%= config.bin %> <%= command.id %> --job-id 0Af0x000017yLUFCA2",
1321
+ "Resume watching the most recent deploy operation:\n<%= config.bin %> <%= command.id %> --use-most-recent"
1571
1322
  ],
1572
1323
  "flags": {
1573
1324
  "json": {
@@ -1585,127 +1336,44 @@
1585
1336
  "multiple": false,
1586
1337
  "type": "option"
1587
1338
  },
1588
- "api-version": {
1589
- "char": "a",
1590
- "description": "Use this flag to override the default API version with the API version of your package.xml file. The default API version is the latest version supported by the CLI.",
1591
- "name": "api-version",
1592
- "summary": "Target API version for the validation.",
1593
- "hasDynamicHelp": false,
1594
- "multiple": false,
1595
- "type": "option"
1596
- },
1597
- "async": {
1598
- "description": "The command immediately returns the job ID and control of the terminal to you. This way, you can continue to use the CLI. To resume watching the validation, run \"<%= config.bin %> project deploy resume\". To check the status of the validation, run \"<%= config.bin %> project deploy report\".",
1599
- "name": "async",
1600
- "summary": "Run the command asynchronously.",
1601
- "allowNo": false,
1602
- "type": "boolean"
1603
- },
1604
1339
  "concise": {
1605
1340
  "exclusive": [
1606
1341
  "verbose"
1607
1342
  ],
1608
1343
  "name": "concise",
1609
- "summary": "Show concise output of the validation result.",
1344
+ "summary": "Show concise output of the deploy operation result.",
1610
1345
  "allowNo": false,
1611
1346
  "type": "boolean"
1612
1347
  },
1613
- "manifest": {
1614
- "char": "x",
1615
- "description": "All child components are included. If you specify this flag, don’t specify --metadata or --source-dir.",
1616
- "helpGroup": "Source Format",
1617
- "name": "manifest",
1618
- "summary": "Full file path for manifest (package.xml) of components to validate for deployment.",
1619
- "hasDynamicHelp": false,
1620
- "multiple": false,
1621
- "type": "option"
1622
- },
1623
- "metadata": {
1624
- "char": "m",
1625
- "helpGroup": "Source Format",
1626
- "name": "metadata",
1627
- "summary": "Metadata component names to validate for deployment.",
1628
- "hasDynamicHelp": false,
1629
- "multiple": true,
1630
- "type": "option"
1631
- },
1632
- "source-dir": {
1633
- "char": "d",
1634
- "description": "The supplied path can be to a single file (in which case the operation is applied to only one file) or to a folder (in which case the operation is applied to all metadata types in the directory and its subdirectories).\n\nIf you specify this flag, don’t specify --metadata or --manifest.",
1635
- "helpGroup": "Source Format",
1636
- "name": "source-dir",
1637
- "summary": "Path to the local source files to validate for deployment.",
1638
- "hasDynamicHelp": false,
1639
- "multiple": true,
1640
- "type": "option"
1641
- },
1642
- "metadata-dir": {
1643
- "helpGroup": "Metadata API Format",
1644
- "name": "metadata-dir",
1645
- "summary": "Root of directory or zip file of metadata formatted files to deploy.",
1348
+ "job-id": {
1349
+ "char": "i",
1350
+ "description": "These commands return a job ID if they time out or you specified the --async flag:\n\n- <%= config.bin %> project deploy start\n- <%= config.bin %> project deploy validate\n- <%= config.bin %> project deploy quick\n- <%= config.bin %> project deploy cancel\n\nThe job ID is valid for 10 days from when you started the deploy operation.",
1351
+ "name": "job-id",
1352
+ "summary": "Job ID of the deploy operation you want to resume.",
1646
1353
  "hasDynamicHelp": false,
1647
1354
  "multiple": false,
1648
1355
  "type": "option"
1649
1356
  },
1650
- "single-package": {
1651
- "dependsOn": [
1652
- "metadata-dir"
1653
- ],
1654
- "helpGroup": "Metadata API Format",
1655
- "name": "single-package",
1656
- "summary": "Indicates that the metadata zip file points to a directory structure for a single package.",
1357
+ "use-most-recent": {
1358
+ "char": "r",
1359
+ "description": "For performance reasons, this flag uses job IDs for deploy operations that started only in the past 3 days or less. If your most recent operation was more than 3 days ago, this flag won't find a job ID.",
1360
+ "name": "use-most-recent",
1361
+ "summary": "Use the job ID of the most recent deploy operation.",
1657
1362
  "allowNo": false,
1658
1363
  "type": "boolean"
1659
1364
  },
1660
- "target-org": {
1661
- "char": "o",
1662
- "name": "target-org",
1663
- "noCacheDefault": true,
1664
- "required": true,
1665
- "summary": "Username or alias of the target org. Not required if the `target-org` configuration variable is already set.",
1666
- "hasDynamicHelp": true,
1667
- "multiple": false,
1668
- "type": "option"
1669
- },
1670
- "tests": {
1671
- "char": "t",
1672
- "description": "If a test name contains a space, enclose it in double quotes.\nFor multiple test names, use one of the following formats:\n\n- Repeat the flag for multiple test names: --tests Test1 --tests Test2 --tests \"Test With Space\"\n- Separate the test names with spaces: --tests Test1 Test2 \"Test With Space\"",
1673
- "helpGroup": "Test",
1674
- "name": "tests",
1675
- "summary": "Apex tests to run when --test-level is RunSpecifiedTests.",
1676
- "hasDynamicHelp": false,
1677
- "multiple": true,
1678
- "type": "option"
1679
- },
1680
- "test-level": {
1681
- "char": "l",
1682
- "description": "Valid values are:\n\n- RunSpecifiedTests — Runs only the tests that you specify with the --tests flag. Code coverage requirements differ from the default coverage requirements when using this test level. Executed tests must comprise a minimum of 75% code coverage for each class and trigger in the deployment package. This coverage is computed for each class and trigger individually and is different than the overall coverage percentage.\n\n- RunLocalTests — All tests in your org are run, except the ones that originate from installed managed and unlocked packages. This test level is the default.\n\n- RunAllTestsInOrg — All tests in your org are run, including tests of managed packages.\n\n- RunRelevantTests — Runs only tests that are relevant to the files being deployed.",
1683
- "helpGroup": "Test",
1684
- "name": "test-level",
1685
- "summary": "Deployment Apex testing level.",
1686
- "default": "RunLocalTests",
1687
- "hasDynamicHelp": false,
1688
- "multiple": false,
1689
- "options": [
1690
- "RunAllTestsInOrg",
1691
- "RunLocalTests",
1692
- "RunSpecifiedTests",
1693
- "RunRelevantTests"
1694
- ],
1695
- "type": "option"
1696
- },
1697
1365
  "verbose": {
1698
1366
  "exclusive": [
1699
1367
  "concise"
1700
1368
  ],
1701
1369
  "name": "verbose",
1702
- "summary": "Show verbose output of the validation result.",
1370
+ "summary": "Show verbose output of the deploy operation result.",
1703
1371
  "allowNo": false,
1704
1372
  "type": "boolean"
1705
1373
  },
1706
1374
  "wait": {
1707
1375
  "char": "w",
1708
- "description": "If the command continues to run after the wait period, the CLI returns control of the terminal window to you and returns the job ID. To resume watching the validation, run \"<%= config.bin %> project deploy resume\". To check the status of the validation, run \"<%= config.bin %> project deploy report\".",
1376
+ "description": "If the command continues to run after the wait period, the CLI returns control of the terminal window to you. To resume watching the deploy operation, run this command again. To check the status of the deploy operation, run \"<%= config.bin %> project deploy report\".",
1709
1377
  "name": "wait",
1710
1378
  "summary": "Number of minutes to wait for the command to complete and display results.",
1711
1379
  "hasDynamicHelp": true,
@@ -1713,14 +1381,6 @@
1713
1381
  "multiple": false,
1714
1382
  "type": "option"
1715
1383
  },
1716
- "ignore-warnings": {
1717
- "char": "g",
1718
- "description": "If you specify this flag, and a warning occurs, the success status of the deployment is set to true. If you don't specify this flag, and a warning occurs, then the success status is set to false, and the warning is treated like an error.\n\nThis flag is useful in a CI environment and your deployment includes destructive changes; if you try to delete a component that doesn't exist in the org, you get a warning. In this case, to ensure that the command returns a success value of true, specify this flag.",
1719
- "name": "ignore-warnings",
1720
- "summary": "Ignore warnings and allow a deployment to complete successfully.",
1721
- "allowNo": false,
1722
- "type": "boolean"
1723
- },
1724
1384
  "coverage-formatters": {
1725
1385
  "description": "For multiple formatters, repeat the flag for each formatter.\n--coverage-formatters lcov --coverage-formatters clover",
1726
1386
  "helpGroup": "Test",
@@ -1766,78 +1426,20 @@
1766
1426
  "hasDynamicHelp": false,
1767
1427
  "multiple": false,
1768
1428
  "type": "option"
1769
- },
1770
- "purge-on-delete": {
1771
- "dependsOn": [
1772
- "manifest"
1773
- ],
1774
- "helpGroup": "Delete",
1775
- "name": "purge-on-delete",
1776
- "relationships": [
1777
- {
1778
- "type": "some",
1779
- "flags": [
1780
- "pre-destructive-changes",
1781
- "post-destructive-changes"
1782
- ]
1783
- }
1784
- ],
1785
- "summary": "Specify that deleted components in the destructive changes manifest file are immediately eligible for deletion rather than being stored in the Recycle Bin.",
1786
- "allowNo": false,
1787
- "type": "boolean"
1788
- },
1789
- "pre-destructive-changes": {
1790
- "dependsOn": [
1791
- "manifest"
1792
- ],
1793
- "helpGroup": "Delete",
1794
- "name": "pre-destructive-changes",
1795
- "summary": "File path for a manifest (destructiveChangesPre.xml) of components to delete before the deploy",
1796
- "hasDynamicHelp": false,
1797
- "multiple": false,
1798
- "type": "option"
1799
- },
1800
- "post-destructive-changes": {
1801
- "dependsOn": [
1802
- "manifest"
1803
- ],
1804
- "helpGroup": "Delete",
1805
- "name": "post-destructive-changes",
1806
- "summary": "File path for a manifest (destructiveChangesPost.xml) of components to delete after the deploy.",
1807
- "hasDynamicHelp": false,
1808
- "multiple": false,
1809
- "type": "option"
1810
1429
  }
1811
1430
  },
1812
1431
  "hasDynamicHelp": true,
1813
1432
  "hiddenAliases": [],
1814
- "id": "project:deploy:validate",
1433
+ "id": "project:deploy:resume",
1815
1434
  "pluginAlias": "@salesforce/plugin-deploy-retrieve",
1816
1435
  "pluginName": "@salesforce/plugin-deploy-retrieve",
1817
1436
  "pluginType": "core",
1818
1437
  "strict": true,
1819
- "summary": "Validate a metadata deployment without actually executing it.",
1438
+ "summary": "Resume watching a deploy operation and update source tracking when the deploy completes.",
1820
1439
  "enableJsonFlag": true,
1821
- "configurationVariablesSection": {
1822
- "header": "CONFIGURATION VARIABLES",
1823
- "body": [
1824
- {
1825
- "name": "target-org",
1826
- "description": "Username or alias of the org that all commands run against by default. (sf only)"
1827
- },
1828
- {
1829
- "name": "org-api-version",
1830
- "description": "API version of your project. Default: API version of your Dev Hub org."
1831
- }
1832
- ]
1833
- },
1834
1440
  "envVariablesSection": {
1835
1441
  "header": "ENVIRONMENT VARIABLES",
1836
1442
  "body": [
1837
- {
1838
- "name": "SF_TARGET_ORG",
1839
- "description": "Username or alias of your default org. Overrides the target-org configuration variable."
1840
- },
1841
1443
  {
1842
1444
  "name": "SF_USE_PROGRESS_BAR",
1843
1445
  "description": "Set to false to disable the progress bar when running the metadata deploy command."
@@ -1883,37 +1485,47 @@
1883
1485
  "commands",
1884
1486
  "project",
1885
1487
  "deploy",
1886
- "validate.js"
1488
+ "resume.js"
1887
1489
  ],
1888
1490
  "aliasPermutations": [
1889
- "deploy:metadata:validate",
1890
- "metadata:deploy:validate",
1891
- "metadata:validate:deploy",
1892
- "deploy:validate:metadata",
1893
- "validate:deploy:metadata",
1894
- "validate:metadata:deploy"
1491
+ "deploy:metadata:resume",
1492
+ "metadata:deploy:resume",
1493
+ "metadata:resume:deploy",
1494
+ "deploy:resume:metadata",
1495
+ "resume:deploy:metadata",
1496
+ "resume:metadata:deploy"
1895
1497
  ],
1896
1498
  "permutations": [
1897
- "project:deploy:validate",
1898
- "deploy:project:validate",
1899
- "deploy:validate:project",
1900
- "project:validate:deploy",
1901
- "validate:project:deploy",
1902
- "validate:deploy:project"
1499
+ "project:deploy:resume",
1500
+ "deploy:project:resume",
1501
+ "deploy:resume:project",
1502
+ "project:resume:deploy",
1503
+ "resume:project:deploy",
1504
+ "resume:deploy:project"
1903
1505
  ]
1904
1506
  },
1905
- "project:delete:source": {
1507
+ "project:deploy:start": {
1906
1508
  "aliases": [
1907
- "force:source:delete"
1509
+ "deploy:metadata"
1908
1510
  ],
1909
1511
  "args": {},
1910
1512
  "deprecateAliases": true,
1911
- "description": "Use this command to delete components from orgs that don’t have source tracking. To remove deleted items from orgs that have source tracking enabled, \"<%= config.bin %> project deploy start\".\n\nWhen you run this command, both the local source file and the metadata component in the org are deleted.\n\nTo delete multiple metadata components, either set multiple --metadata <name> flags or a single --metadata flag with multiple names separated by spaces. Enclose names that contain spaces in one set of double quotes. The same syntax applies to --source-dir.",
1513
+ "description": "You must run this command from within a project.\n\nMetadata components are deployed in source format by default. Deploy them in metadata format by specifying the --metadata-dir flag, which specifies the root directory or ZIP file that contains the metadata formatted files you want to deploy.\n\nIf your org allows source tracking, then this command tracks the changes in your source. Some orgs, such as production orgs, never allow source tracking. Source tracking is enabled by default on scratch and sandbox orgs; you can disable source tracking when you create the orgs by specifying the --no-track-source flag on the \"<%= config.bin %> org create scratch|sandbox\" commands.\n\nTo deploy multiple metadata components, either set multiple --metadata <name> flags or a single --metadata flag with multiple names separated by spaces. Enclose names that contain spaces in one set of double quotes. The same syntax applies to --source-dir.",
1912
1514
  "examples": [
1913
- "Delete all local Apex source files and all Apex classes from the org with alias \"my-scratch\":\n<%= config.bin %> <%= command.id %> --metadata ApexClass --target-org my-scratch",
1914
- "Delete a specific Apex class and a Profile that has a space in it from your default org; don't prompt for confirmation:\n<%= config.bin %> <%= command.id %> --metadata ApexClass:MyFabulousApexClass --metadata \"Profile: My Profile\" --no-prompt",
1915
- "Run the tests that aren’t in any managed packages as part of the deletion; if the delete succeeds, and the org has source-tracking enabled, update the source tracking information:\n<%= config.bin %> <%= command.id %> --metadata ApexClass --test-level RunLocalTests --track-source",
1916
- "Delete the Apex source files in a directory and the corresponding components from your default org:\n<%= config.bin %> <%= command.id %> --source-dir force-app/main/default/classes"
1515
+ "Deploy local changes not in the org; uses your default org:\n<%= config.bin %> <%= command.id %>",
1516
+ "Deploy all source files in the \"force-app\" directory to an org with alias \"my-scratch\"; show only concise output, in other words don't print a list of all the source that was deployed:\n<%= config.bin %> <%= command.id %> --source-dir force-app --target-org my-scratch --concise",
1517
+ "Deploy all the Apex classes and custom objects that are in the \"force-app\" directory. The list views, layouts, etc, that are associated with the custom objects are also deployed. Both examples are equivalent:\n<%= config.bin %> <%= command.id %> --source-dir force-app/main/default/classes force-app/main/default/objects\n<%= config.bin %> <%= command.id %> --source-dir force-app/main/default/classes --source-dir force-app/main/default/objects",
1518
+ "Deploy all Apex classes that are in all package directories defined in the \"sfdx-project.json\" file:\n<%= config.bin %> <%= command.id %> --metadata ApexClass",
1519
+ "Deploy a specific Apex class; ignore any conflicts between the local project and org (be careful with this flag, because it will overwrite the Apex class in the org if there are conflicts!):\n<%= config.bin %> <%= command.id %> --metadata ApexClass:MyApexClass --ignore-conflicts",
1520
+ "Deploy specific Apex classes that match a pattern; in this example, deploy Apex classes whose names contain the string \"MyApex\". Also ignore any deployment warnings (again, be careful with this flag! You typically want to see the warnings):\n<%= config.bin %> <%= command.id %> --metadata 'ApexClass:MyApex*' --ignore-warnings",
1521
+ "Deploy a custom object called ExcitingObject that's in the SBQQ namespace:\nsf <%= command.id %> --metadata CustomObject:SBQQ__ExcitingObject",
1522
+ "Deploy all custom objects in the SBQQ namespace by using a wildcard and quotes:\nsf <%= command.id %> --metadata 'CustomObject:SBQQ__*'",
1523
+ "Deploy all custom objects and Apex classes found in all defined package directories (both examples are equivalent):\n<%= config.bin %> <%= command.id %> --metadata CustomObject ApexClass\n<%= config.bin %> <%= command.id %> --metadata CustomObject --metadata ApexClass",
1524
+ "Deploy all Apex classes and a profile that has a space in its name:\n<%= config.bin %> <%= command.id %> --metadata ApexClass --metadata \"Profile:My Profile\"",
1525
+ "Deploy all components listed in a manifest:\n<%= config.bin %> <%= command.id %> --manifest path/to/package.xml",
1526
+ "Run the tests that aren’t in any managed packages as part of a deployment:\n<%= config.bin %> <%= command.id %> --metadata ApexClass --test-level RunLocalTests",
1527
+ "Deploy all metadata formatted files in the \"MDAPI\" directory:\n<%= config.bin %> <%= command.id %> --metadata-dir MDAPI",
1528
+ "Deploy all metadata formatted files in the \"MDAPI\" directory; items listed in the MDAPI/destructiveChangesPre.xml and MDAPI/destructiveChangesPost.xml manifests are immediately eligible for deletion rather than stored in the Recycle Bin:\n<%= config.bin %> <%= command.id %> --metadata-dir MDAPI --purge-on-delete"
1917
1529
  ],
1918
1530
  "flags": {
1919
1531
  "json": {
@@ -1932,63 +1544,142 @@
1932
1544
  "type": "option"
1933
1545
  },
1934
1546
  "api-version": {
1935
- "aliases": [
1936
- "apiversion"
1937
- ],
1938
- "deprecateAliases": true,
1939
- "description": "Override the api version used for api requests made by this command",
1547
+ "char": "a",
1548
+ "description": "Use this flag to override the default API version with the API version of your package.xml file. The default API version is the latest version supported by the CLI.",
1940
1549
  "name": "api-version",
1550
+ "summary": "Target API version for the deploy.",
1941
1551
  "hasDynamicHelp": false,
1942
1552
  "multiple": false,
1943
1553
  "type": "option"
1944
1554
  },
1945
- "loglevel": {
1946
- "deprecated": {
1947
- "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."
1948
- },
1949
- "hidden": true,
1950
- "name": "loglevel",
1555
+ "async": {
1556
+ "description": "The command immediately returns the job ID and control of the terminal to you. This way, you can continue to use the CLI. To resume the deployment, run \"<%= config.bin %> project deploy resume\". To check the status of the deployment, run \"<%= config.bin %> project deploy report\".",
1557
+ "exclusive": [
1558
+ "wait"
1559
+ ],
1560
+ "name": "async",
1561
+ "summary": "Run the command asynchronously.",
1562
+ "allowNo": false,
1563
+ "type": "boolean"
1564
+ },
1565
+ "concise": {
1566
+ "exclusive": [
1567
+ "verbose"
1568
+ ],
1569
+ "name": "concise",
1570
+ "summary": "Show concise output of the deploy result.",
1571
+ "allowNo": false,
1572
+ "type": "boolean"
1573
+ },
1574
+ "dry-run": {
1575
+ "name": "dry-run",
1576
+ "summary": "Validate deploy and run Apex tests but don’t save to the org.",
1577
+ "allowNo": false,
1578
+ "type": "boolean"
1579
+ },
1580
+ "ignore-conflicts": {
1581
+ "char": "c",
1582
+ "description": "This flag applies only to orgs that allow source tracking. It has no effect on orgs that don't allow it, such as production orgs.",
1583
+ "name": "ignore-conflicts",
1584
+ "summary": "Ignore conflicts and deploy local files, even if they overwrite changes in the org.",
1585
+ "allowNo": false,
1586
+ "type": "boolean"
1587
+ },
1588
+ "ignore-errors": {
1589
+ "char": "r",
1590
+ "description": "Never use this flag when deploying to a production org. If you specify it, components without errors are deployed and components with errors are skipped, and could result in an inconsistent production org.",
1591
+ "name": "ignore-errors",
1592
+ "summary": "Ignore any errors and don’t roll back deployment.",
1593
+ "allowNo": false,
1594
+ "type": "boolean"
1595
+ },
1596
+ "ignore-warnings": {
1597
+ "char": "g",
1598
+ "description": "If you specify this flag, and a warning occurs, the success status of the deployment is set to true. If you don't specify this flag, and a warning occurs, then the success status is set to false, and the warning is treated like an error.\n\nThis flag is useful in a CI environment and your deployment includes destructive changes; if you try to delete a component that doesn't exist in the org, you get a warning. In this case, to ensure that the command returns a success value of true, specify this flag.",
1599
+ "name": "ignore-warnings",
1600
+ "summary": "Ignore warnings and allow a deployment to complete successfully.",
1601
+ "allowNo": false,
1602
+ "type": "boolean"
1603
+ },
1604
+ "manifest": {
1605
+ "char": "x",
1606
+ "description": "All child components are included. If you specify this flag, don’t specify --metadata or --source-dir.",
1607
+ "exclusive": [
1608
+ "source-dir",
1609
+ "metadata",
1610
+ "metadata-dir"
1611
+ ],
1612
+ "helpGroup": "Source Format",
1613
+ "name": "manifest",
1614
+ "summary": "Full file path for manifest (package.xml) of components to deploy.",
1951
1615
  "hasDynamicHelp": false,
1952
1616
  "multiple": false,
1953
1617
  "type": "option"
1954
1618
  },
1955
- "target-org": {
1956
- "aliases": [
1957
- "targetusername",
1958
- "u"
1619
+ "metadata": {
1620
+ "char": "m",
1621
+ "exclusive": [
1622
+ "manifest",
1623
+ "source-dir",
1624
+ "metadata-dir"
1959
1625
  ],
1960
- "char": "o",
1961
- "deprecateAliases": true,
1962
- "name": "target-org",
1963
- "noCacheDefault": true,
1964
- "required": true,
1965
- "summary": "Username or alias of the target org. Not required if the `target-org` configuration variable is already set.",
1966
- "hasDynamicHelp": true,
1626
+ "helpGroup": "Source Format",
1627
+ "name": "metadata",
1628
+ "summary": "Metadata component names to deploy. Wildcards (`*` ) supported as long as you use quotes, such as `ApexClass:MyClass*`.",
1629
+ "hasDynamicHelp": false,
1630
+ "multiple": true,
1631
+ "type": "option"
1632
+ },
1633
+ "metadata-dir": {
1634
+ "exclusive": [
1635
+ "manifest",
1636
+ "source-dir",
1637
+ "metadata"
1638
+ ],
1639
+ "helpGroup": "Metadata API Format",
1640
+ "name": "metadata-dir",
1641
+ "summary": "Root of directory or zip file of metadata formatted files to deploy.",
1642
+ "hasDynamicHelp": false,
1967
1643
  "multiple": false,
1968
1644
  "type": "option"
1969
1645
  },
1970
- "check-only": {
1971
- "aliases": [
1972
- "checkonly"
1646
+ "single-package": {
1647
+ "dependsOn": [
1648
+ "metadata-dir"
1973
1649
  ],
1974
- "char": "c",
1975
- "deprecateAliases": true,
1976
- "description": "IMPORTANT: Where possible, we changed noninclusive terms to align with our company value of Equality. We maintained certain terms to avoid any effect on customer implementations.\n\nValidates the deleted metadata and runs all Apex tests, but prevents the deletion from being saved to the org.\n\nIf you change a field type from Master-Detail to Lookup or vice versa, that change isn’t supported when using the --check-only flag to test a deletion (validation). This kind of change isn’t supported for test deletions to avoid the risk of data loss or corruption. If a change that isn’t supported for test deletions is included in a deletion package, the test deletion fails and issues an error.\n\nIf your deletion package changes a field type from Master-Detail to Lookup or vice versa, you can still validate the changes prior to deploying to Production by performing a full deletion to another test Sandbox. A full deletion includes a validation of the changes as part of the deletion process.\n\nNote: A Metadata API deletion that includes Master-Detail relationships deletes all detail records in the Recycle Bin in the following cases.\n\n 1. For a deletion with a new Master-Detail field, soft delete (send to the Recycle Bin) all detail records before proceeding to delete the Master-Detail field, or the deletion fails. During the deletion, detail records are permanently deleted from the Recycle Bin and cannot be recovered.\n\n 2. For a deletion that converts a Lookup field relationship to a Master-Detail relationship, detail records must reference a master record or be soft-deleted (sent to the Recycle Bin) for the deletion to succeed. However, a successful deletion permanently deletes any detail records in the Recycle Bin.",
1977
- "name": "check-only",
1978
- "summary": "Validate delete command but don't delete anything from the org or the local project.",
1650
+ "helpGroup": "Metadata API Format",
1651
+ "name": "single-package",
1652
+ "summary": "Indicates that the metadata zip file points to a directory structure for a single package.",
1979
1653
  "allowNo": false,
1980
1654
  "type": "boolean"
1981
1655
  },
1982
- "wait": {
1983
- "char": "w",
1984
- "description": "If the command continues to run after the wait period, the CLI returns control of the terminal window to you.",
1985
- "name": "wait",
1986
- "summary": "Number of minutes to wait for the command to finish.",
1656
+ "source-dir": {
1657
+ "char": "d",
1658
+ "description": "The supplied path can be to a single file (in which case the operation is applied to only one file) or to a folder (in which case the operation is applied to all metadata types in the directory and its subdirectories).\n\nIf you specify this flag, don’t specify --metadata or --manifest.",
1659
+ "exclusive": [
1660
+ "manifest",
1661
+ "metadata",
1662
+ "metadata-dir"
1663
+ ],
1664
+ "helpGroup": "Source Format",
1665
+ "name": "source-dir",
1666
+ "summary": "Path to the local source files to deploy.",
1667
+ "hasDynamicHelp": false,
1668
+ "multiple": true,
1669
+ "type": "option"
1670
+ },
1671
+ "target-org": {
1672
+ "char": "o",
1673
+ "name": "target-org",
1674
+ "noCacheDefault": true,
1675
+ "required": true,
1676
+ "summary": "Username or alias of the target org. Not required if the `target-org` configuration variable is already set.",
1987
1677
  "hasDynamicHelp": true,
1988
1678
  "multiple": false,
1989
1679
  "type": "option"
1990
1680
  },
1991
1681
  "tests": {
1682
+ "char": "t",
1992
1683
  "description": "If a test name contains a space, enclose it in double quotes.\nFor multiple test names, use one of the following formats:\n\n- Repeat the flag for multiple test names: --tests Test1 --tests Test2 --tests \"Test With Space\"\n- Separate the test names with spaces: --tests Test1 Test2 \"Test With Space\"",
1993
1684
  "helpGroup": "Test",
1994
1685
  "name": "tests",
@@ -1998,12 +1689,8 @@
1998
1689
  "type": "option"
1999
1690
  },
2000
1691
  "test-level": {
2001
- "aliases": [
2002
- "testlevel"
2003
- ],
2004
1692
  "char": "l",
2005
- "deprecateAliases": true,
2006
- "description": "Valid values are:\n\n- NoTestRun — No tests are run. This test level applies only to deployments to development environments, such as sandbox, Developer Edition, or trial orgs. This test level is the default for development environments.\n\n- RunSpecifiedTests — Runs only the tests that you specify with the --tests flag. Code coverage requirements differ from the default coverage requirements when using this test level. Executed tests must comprise a minimum of 75% code coverage for each class and trigger in the deployment package. This coverage is computed for each class and trigger individually and is different than the overall coverage percentage.\n\n- RunLocalTests — All tests in your org are run, except the ones that originate from installed managed and unlocked packages. This test level is the default for production deployments that include Apex classes or triggers.\n\n- RunAllTestsInOrg — All tests in your org are run, including tests of managed packages.\n\nIf you don’t specify a test level, the default behavior depends on the contents of your deployment package and target org. For more information, see “Running Tests in a Deployment” in the Metadata API Developer Guide.",
1693
+ "description": "Valid values are:\n\n- NoTestRun — No tests are run. This test level applies only to deployments to development environments, such as sandbox, Developer Edition, or trial orgs. This test level is the default for development environments.\n\n- RunSpecifiedTests — Runs only the tests that you specify with the --tests flag. Code coverage requirements differ from the default coverage requirements when using this test level. Executed tests must comprise a minimum of 75% code coverage for each class and trigger in the deployment package. This coverage is computed for each class and trigger individually and is different than the overall coverage percentage.\n\n- RunLocalTests — All tests in your org are run, except the ones that originate from installed managed and unlocked packages. This test level is the default for production deployments that include Apex classes or triggers.\n\n- RunAllTestsInOrg — All tests in your org are run, including tests of managed packages.\n\n- RunRelevantTests (Beta) — Runs only tests that are relevant to the files being deployed. Salesforce automatically identifies the relevant tests based on an analysis of the deployment payload and the payload dependencies. For fine-grained control, you can also annotate test classes so that they always run in certain conditions. See \"@IsTest Annotation\" in the \"Apex Developer Guide\" (https://developer.salesforce.com/docs/atlas.en-us.apexcode.meta/apexcode/apex_classes_annotation_isTest.htm). Each class and trigger in the deployment package must be covered by the executed tests for a minimum of 75% code coverage. This coverage is computed for each class and triggers individually and is different than the overall coverage percentage.\n\nIf you don’t specify a test level, the default behavior depends on the contents of your deployment package and target org. For more information, see \"Running Tests in a Deployment\" (https://developer.salesforce.com/docs/atlas.en-us.api_meta.meta/api_meta/meta_deploy_running_tests.htm) in the \"Metadata API Developer Guide\".",
2007
1694
  "helpGroup": "Test",
2008
1695
  "name": "test-level",
2009
1696
  "summary": "Deployment Apex testing level.",
@@ -2018,120 +1705,217 @@
2018
1705
  ],
2019
1706
  "type": "option"
2020
1707
  },
2021
- "no-prompt": {
2022
- "aliases": [
2023
- "noprompt"
1708
+ "verbose": {
1709
+ "exclusive": [
1710
+ "concise"
2024
1711
  ],
2025
- "char": "r",
2026
- "deprecateAliases": true,
2027
- "name": "no-prompt",
2028
- "summary": "Don't prompt for delete confirmation.",
1712
+ "name": "verbose",
1713
+ "summary": "Show verbose output of the deploy result.",
2029
1714
  "allowNo": false,
2030
1715
  "type": "boolean"
2031
1716
  },
2032
- "metadata": {
2033
- "char": "m",
2034
- "description": "If you specify this flag, don’t specify --source-dir.",
2035
- "name": "metadata",
2036
- "summary": "Metadata components to delete.",
2037
- "delimiter": ",",
2038
- "hasDynamicHelp": false,
2039
- "multiple": true,
2040
- "type": "option"
2041
- },
2042
- "source-dir": {
2043
- "aliases": [
2044
- "sourcepath"
1717
+ "wait": {
1718
+ "char": "w",
1719
+ "description": "If the command continues to run after the wait period, the CLI returns control of the terminal window to you and returns the job ID. To resume the deployment, run \"<%= config.bin %> project deploy resume\". To check the status of the deployment, run \"<%= config.bin %> project deploy report\".",
1720
+ "exclusive": [
1721
+ "async"
2045
1722
  ],
2046
- "char": "p",
2047
- "deprecateAliases": true,
2048
- "description": "The supplied paths can be a single file (in which case the operation is applied to only one file) or a folder (in which case the operation is applied to all metadata types in the directory and its sub-directories).\n\nIf you specify this flag, don’t specify --metadata.",
2049
- "name": "source-dir",
2050
- "summary": "Source file paths to delete.",
2051
- "delimiter": ",",
2052
- "hasDynamicHelp": false,
2053
- "multiple": true,
1723
+ "name": "wait",
1724
+ "summary": "Number of minutes to wait for command to complete and display results.",
1725
+ "hasDynamicHelp": true,
1726
+ "helpValue": "<minutes>",
1727
+ "multiple": false,
2054
1728
  "type": "option"
2055
1729
  },
2056
- "track-source": {
2057
- "aliases": [
2058
- "tracksource"
2059
- ],
2060
- "char": "t",
2061
- "deprecateAliases": true,
2062
- "exclusive": [
2063
- "check-only"
2064
- ],
2065
- "name": "track-source",
2066
- "summary": "If the delete succeeds, update the source tracking information.",
1730
+ "purge-on-delete": {
1731
+ "helpGroup": "Delete",
1732
+ "name": "purge-on-delete",
1733
+ "relationships": [
1734
+ {
1735
+ "type": "some",
1736
+ "flags": [
1737
+ "pre-destructive-changes",
1738
+ "manifest",
1739
+ "metadata-dir",
1740
+ "post-destructive-changes"
1741
+ ]
1742
+ }
1743
+ ],
1744
+ "summary": "Specify that deleted components in the destructive changes manifest file are immediately eligible for deletion rather than being stored in the Recycle Bin.",
2067
1745
  "allowNo": false,
2068
1746
  "type": "boolean"
2069
1747
  },
2070
- "force-overwrite": {
2071
- "aliases": [
2072
- "forceoverwrite"
1748
+ "pre-destructive-changes": {
1749
+ "dependsOn": [
1750
+ "manifest"
2073
1751
  ],
2074
- "char": "f",
1752
+ "helpGroup": "Delete",
1753
+ "name": "pre-destructive-changes",
1754
+ "summary": "File path for a manifest (destructiveChangesPre.xml) of components to delete before the deploy.",
1755
+ "hasDynamicHelp": false,
1756
+ "multiple": false,
1757
+ "type": "option"
1758
+ },
1759
+ "post-destructive-changes": {
2075
1760
  "dependsOn": [
2076
- "track-source"
1761
+ "manifest"
2077
1762
  ],
2078
- "deprecateAliases": true,
2079
- "name": "force-overwrite",
2080
- "summary": "Ignore conflict warnings and overwrite changes to the org.",
2081
- "allowNo": false,
2082
- "type": "boolean"
1763
+ "helpGroup": "Delete",
1764
+ "name": "post-destructive-changes",
1765
+ "summary": "File path for a manifest (destructiveChangesPost.xml) of components to delete after the deploy.",
1766
+ "hasDynamicHelp": false,
1767
+ "multiple": false,
1768
+ "type": "option"
2083
1769
  },
2084
- "verbose": {
2085
- "name": "verbose",
2086
- "summary": "Verbose output of the delete result.",
1770
+ "coverage-formatters": {
1771
+ "description": "For multiple formatters, repeat the flag for each formatter.\n--coverage-formatters lcov --coverage-formatters clover",
1772
+ "helpGroup": "Test",
1773
+ "name": "coverage-formatters",
1774
+ "summary": "Format of the code coverage results.",
1775
+ "hasDynamicHelp": false,
1776
+ "multiple": true,
1777
+ "options": [
1778
+ "clover",
1779
+ "cobertura",
1780
+ "html-spa",
1781
+ "html",
1782
+ "json",
1783
+ "json-summary",
1784
+ "lcovonly",
1785
+ "none",
1786
+ "teamcity",
1787
+ "text",
1788
+ "text-summary"
1789
+ ],
1790
+ "type": "option"
1791
+ },
1792
+ "junit": {
1793
+ "helpGroup": "Test",
1794
+ "name": "junit",
1795
+ "summary": "Output JUnit test results.",
2087
1796
  "allowNo": false,
2088
1797
  "type": "boolean"
1798
+ },
1799
+ "results-dir": {
1800
+ "helpGroup": "Test",
1801
+ "name": "results-dir",
1802
+ "relationships": [
1803
+ {
1804
+ "type": "some",
1805
+ "flags": [
1806
+ "coverage-formatters",
1807
+ "junit"
1808
+ ]
1809
+ }
1810
+ ],
1811
+ "summary": "Output directory for code coverage and JUnit results; defaults to the deploy ID.",
1812
+ "hasDynamicHelp": false,
1813
+ "multiple": false,
1814
+ "type": "option"
2089
1815
  }
2090
1816
  },
2091
1817
  "hasDynamicHelp": true,
2092
1818
  "hiddenAliases": [],
2093
- "id": "project:delete:source",
1819
+ "id": "project:deploy:start",
2094
1820
  "pluginAlias": "@salesforce/plugin-deploy-retrieve",
2095
1821
  "pluginName": "@salesforce/plugin-deploy-retrieve",
2096
1822
  "pluginType": "core",
2097
1823
  "strict": true,
2098
- "summary": "Delete source from your project and from a non-source-tracked org.",
1824
+ "summary": "Deploy metadata to an org from your local project.",
2099
1825
  "enableJsonFlag": true,
2100
- "requiresProject": true,
1826
+ "configurationVariablesSection": {
1827
+ "header": "CONFIGURATION VARIABLES",
1828
+ "body": [
1829
+ {
1830
+ "name": "target-org",
1831
+ "description": "Username or alias of the org that all commands run against by default. (sf only)"
1832
+ },
1833
+ {
1834
+ "name": "org-api-version",
1835
+ "description": "API version of your project. Default: API version of your Dev Hub org."
1836
+ }
1837
+ ]
1838
+ },
1839
+ "envVariablesSection": {
1840
+ "header": "ENVIRONMENT VARIABLES",
1841
+ "body": [
1842
+ {
1843
+ "name": "SF_TARGET_ORG",
1844
+ "description": "Username or alias of your default org. Overrides the target-org configuration variable."
1845
+ },
1846
+ {
1847
+ "name": "SF_USE_PROGRESS_BAR",
1848
+ "description": "Set to false to disable the progress bar when running the metadata deploy command."
1849
+ }
1850
+ ]
1851
+ },
1852
+ "errorCodes": {
1853
+ "header": "ERROR CODES",
1854
+ "body": [
1855
+ {
1856
+ "name": "Succeeded (0)",
1857
+ "description": "The deploy succeeded."
1858
+ },
1859
+ {
1860
+ "name": "Canceled (1)",
1861
+ "description": "The deploy was canceled."
1862
+ },
1863
+ {
1864
+ "name": "Failed (1)",
1865
+ "description": "The deploy failed."
1866
+ },
1867
+ {
1868
+ "name": "SucceededPartial (68)",
1869
+ "description": "The deploy partially succeeded."
1870
+ },
1871
+ {
1872
+ "name": "InProgress (69)",
1873
+ "description": "The deploy is in progress."
1874
+ },
1875
+ {
1876
+ "name": "Pending (69)",
1877
+ "description": "The deploy is pending."
1878
+ },
1879
+ {
1880
+ "name": "Canceling (69)",
1881
+ "description": "The deploy is being canceled."
1882
+ }
1883
+ ]
1884
+ },
2101
1885
  "isESM": true,
2102
1886
  "relativePath": [
2103
1887
  "lib",
2104
1888
  "commands",
2105
1889
  "project",
2106
- "delete",
2107
- "source.js"
1890
+ "deploy",
1891
+ "start.js"
2108
1892
  ],
2109
1893
  "aliasPermutations": [
2110
- "force:source:delete",
2111
- "source:force:delete",
2112
- "source:delete:force",
2113
- "force:delete:source",
2114
- "delete:force:source",
2115
- "delete:source:force"
1894
+ "deploy:metadata",
1895
+ "metadata:deploy"
2116
1896
  ],
2117
1897
  "permutations": [
2118
- "project:delete:source",
2119
- "delete:project:source",
2120
- "delete:source:project",
2121
- "project:source:delete",
2122
- "source:project:delete",
2123
- "source:delete:project"
1898
+ "project:deploy:start",
1899
+ "deploy:project:start",
1900
+ "deploy:start:project",
1901
+ "project:start:deploy",
1902
+ "start:project:deploy",
1903
+ "start:deploy:project"
2124
1904
  ]
2125
1905
  },
2126
- "project:delete:tracking": {
1906
+ "project:deploy:validate": {
2127
1907
  "aliases": [
2128
- "force:source:tracking:clear"
1908
+ "deploy:metadata:validate"
2129
1909
  ],
2130
1910
  "args": {},
2131
1911
  "deprecateAliases": true,
2132
- "description": "WARNING: This command deletes or overwrites all existing source tracking files. Use with extreme caution.\n\nDeletes all local source tracking information. When you next run 'project deploy preview', Salesforce CLI displays all local and remote files as changed, and any files with the same name are listed as conflicts.",
1912
+ "description": "Use this command to verify whether a deployment will succeed without actually deploying the metadata to your org. This command is similar to \"<%= config.bin %> project deploy start\", except you're required to run Apex tests, and the command returns a job ID rather than executing the deployment. If the validation succeeds, then you pass this job ID to the \"<%= config.bin %> project deploy quick\" command to actually deploy the metadata. This quick deploy takes less time because it skips running Apex tests. The job ID is valid for 10 days from when you started the validation. Validating first is useful if the deployment to your production org take several hours and you don’t want to risk a failed deploy.\n\nYou must run this command from within a project.\n\nThis command doesn't support source-tracking. When you quick deploy with the resulting job ID, the source you deploy overwrites the corresponding metadata in your org.\n\nTo validate the deployment of multiple metadata components, either set multiple --metadata <name> flags or a single --metadata flag with multiple names separated by spaces. Enclose names that contain spaces in one set of double quotes. The same syntax applies to --source-dir.\n\nNote: Don't use this command on sandboxes; the command is intended to be used on production orgs. By default, sandboxes don't run tests during a deploy. If you want to validate a deployment with tests on a sandbox, use \"<%= config.bin %> project deploy start --dry-run --test-level RunLocalTests\" instead.",
2133
1913
  "examples": [
2134
- "Delete local source tracking for the org with alias \"my-scratch\":\n$ <%= config.bin %> <%= command.id %> --target-org my-scratch"
1914
+ "NOTE: These examples focus on validating large deployments. See the help for \"<%= config.bin %> project deploy start\" for examples of deploying smaller sets of metadata which you can also use to validate.",
1915
+ "Validate the deployment of all source files in the \"force-app\" directory to the default org:\n<%= config.bin %> <%= command.id %> --source-dir force-app",
1916
+ "Validate the deployment of all source files in two directories: \"force-app\" and \"force-app-utils\":\n<%= config.bin %> <%= command.id %> --source-dir force-app --source-dir force-app-utils",
1917
+ "Asynchronously validate the deployment and run all tests in the org with alias \"my-prod-org\"; command immediately returns the job ID:\n<%= config.bin %> <%= command.id %> --source-dir force-app --async --test-level RunAllTestsInOrg --target-org my-prod-org",
1918
+ "Validate the deployment of all components listed in a manifest:\n<%= config.bin %> <%= command.id %> --manifest path/to/package.xml"
2135
1919
  ],
2136
1920
  "flags": {
2137
1921
  "json": {
@@ -2150,104 +1934,320 @@
2150
1934
  "type": "option"
2151
1935
  },
2152
1936
  "api-version": {
2153
- "aliases": [
2154
- "apiversion"
2155
- ],
2156
- "deprecateAliases": true,
2157
- "description": "Override the api version used for api requests made by this command",
1937
+ "char": "a",
1938
+ "description": "Use this flag to override the default API version with the API version of your package.xml file. The default API version is the latest version supported by the CLI.",
2158
1939
  "name": "api-version",
1940
+ "summary": "Target API version for the validation.",
2159
1941
  "hasDynamicHelp": false,
2160
1942
  "multiple": false,
2161
1943
  "type": "option"
2162
1944
  },
2163
- "loglevel": {
2164
- "deprecated": {
2165
- "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."
2166
- },
2167
- "hidden": true,
2168
- "name": "loglevel",
1945
+ "async": {
1946
+ "description": "The command immediately returns the job ID and control of the terminal to you. This way, you can continue to use the CLI. To resume watching the validation, run \"<%= config.bin %> project deploy resume\". To check the status of the validation, run \"<%= config.bin %> project deploy report\".",
1947
+ "name": "async",
1948
+ "summary": "Run the command asynchronously.",
1949
+ "allowNo": false,
1950
+ "type": "boolean"
1951
+ },
1952
+ "concise": {
1953
+ "exclusive": [
1954
+ "verbose"
1955
+ ],
1956
+ "name": "concise",
1957
+ "summary": "Show concise output of the validation result.",
1958
+ "allowNo": false,
1959
+ "type": "boolean"
1960
+ },
1961
+ "manifest": {
1962
+ "char": "x",
1963
+ "description": "All child components are included. If you specify this flag, don’t specify --metadata or --source-dir.",
1964
+ "helpGroup": "Source Format",
1965
+ "name": "manifest",
1966
+ "summary": "Full file path for manifest (package.xml) of components to validate for deployment.",
2169
1967
  "hasDynamicHelp": false,
2170
1968
  "multiple": false,
2171
1969
  "type": "option"
2172
1970
  },
2173
- "target-org": {
2174
- "aliases": [
2175
- "targetusername",
2176
- "u"
2177
- ],
2178
- "char": "o",
2179
- "deprecateAliases": true,
2180
- "name": "target-org",
2181
- "noCacheDefault": true,
2182
- "required": true,
2183
- "summary": "Username or alias of the target org. Not required if the `target-org` configuration variable is already set.",
2184
- "hasDynamicHelp": true,
2185
- "multiple": false,
1971
+ "metadata": {
1972
+ "char": "m",
1973
+ "helpGroup": "Source Format",
1974
+ "name": "metadata",
1975
+ "summary": "Metadata component names to validate for deployment.",
1976
+ "hasDynamicHelp": false,
1977
+ "multiple": true,
2186
1978
  "type": "option"
2187
1979
  },
2188
- "no-prompt": {
2189
- "aliases": [
2190
- "noprompt"
2191
- ],
2192
- "char": "p",
2193
- "deprecateAliases": true,
2194
- "name": "no-prompt",
2195
- "summary": "Don't prompt for source tracking override confirmation.",
2196
- "allowNo": false,
2197
- "type": "boolean"
2198
- }
1980
+ "source-dir": {
1981
+ "char": "d",
1982
+ "description": "The supplied path can be to a single file (in which case the operation is applied to only one file) or to a folder (in which case the operation is applied to all metadata types in the directory and its subdirectories).\n\nIf you specify this flag, don’t specify --metadata or --manifest.",
1983
+ "helpGroup": "Source Format",
1984
+ "name": "source-dir",
1985
+ "summary": "Path to the local source files to validate for deployment.",
1986
+ "hasDynamicHelp": false,
1987
+ "multiple": true,
1988
+ "type": "option"
1989
+ },
1990
+ "metadata-dir": {
1991
+ "helpGroup": "Metadata API Format",
1992
+ "name": "metadata-dir",
1993
+ "summary": "Root of directory or zip file of metadata formatted files to deploy.",
1994
+ "hasDynamicHelp": false,
1995
+ "multiple": false,
1996
+ "type": "option"
1997
+ },
1998
+ "single-package": {
1999
+ "dependsOn": [
2000
+ "metadata-dir"
2001
+ ],
2002
+ "helpGroup": "Metadata API Format",
2003
+ "name": "single-package",
2004
+ "summary": "Indicates that the metadata zip file points to a directory structure for a single package.",
2005
+ "allowNo": false,
2006
+ "type": "boolean"
2007
+ },
2008
+ "target-org": {
2009
+ "char": "o",
2010
+ "name": "target-org",
2011
+ "noCacheDefault": true,
2012
+ "required": true,
2013
+ "summary": "Username or alias of the target org. Not required if the `target-org` configuration variable is already set.",
2014
+ "hasDynamicHelp": true,
2015
+ "multiple": false,
2016
+ "type": "option"
2017
+ },
2018
+ "tests": {
2019
+ "char": "t",
2020
+ "description": "If a test name contains a space, enclose it in double quotes.\nFor multiple test names, use one of the following formats:\n\n- Repeat the flag for multiple test names: --tests Test1 --tests Test2 --tests \"Test With Space\"\n- Separate the test names with spaces: --tests Test1 Test2 \"Test With Space\"",
2021
+ "helpGroup": "Test",
2022
+ "name": "tests",
2023
+ "summary": "Apex tests to run when --test-level is RunSpecifiedTests.",
2024
+ "hasDynamicHelp": false,
2025
+ "multiple": true,
2026
+ "type": "option"
2027
+ },
2028
+ "test-level": {
2029
+ "char": "l",
2030
+ "description": "Valid values are:\n\n- RunSpecifiedTests — Runs only the tests that you specify with the --tests flag. Code coverage requirements differ from the default coverage requirements when using this test level. Executed tests must comprise a minimum of 75% code coverage for each class and trigger in the deployment package. This coverage is computed for each class and trigger individually and is different than the overall coverage percentage.\n\n- RunLocalTests — All tests in your org are run, except the ones that originate from installed managed and unlocked packages. This test level is the default.\n\n- RunAllTestsInOrg — All tests in your org are run, including tests of managed packages.\n\n- RunRelevantTests (Beta) — Runs only tests that are relevant to the files being deployed. Salesforce automatically identifies the relevant tests based on an analysis of the deployment payload and the payload dependencies. For fine-grained control, you can also annotate test classes so that they always run in certain conditions. See \"@IsTest Annotation\" in the \"Apex Developer Guide\" (https://developer.salesforce.com/docs/atlas.en-us.apexcode.meta/apexcode/apex_classes_annotation_isTest.htm). Each class and trigger in the deployment package must be covered by the executed tests for a minimum of 75% code coverage. This coverage is computed for each class and triggers individually and is different than the overall coverage percentage.\n\nIf you don’t specify a test level, the default behavior depends on the contents of your deployment package and target org. For more information, see \"Running Tests in a Deployment\" (https://developer.salesforce.com/docs/atlas.en-us.api_meta.meta/api_meta/meta_deploy_running_tests.htm) in the \"Metadata API Developer Guide\".",
2031
+ "helpGroup": "Test",
2032
+ "name": "test-level",
2033
+ "summary": "Deployment Apex testing level.",
2034
+ "default": "RunLocalTests",
2035
+ "hasDynamicHelp": false,
2036
+ "multiple": false,
2037
+ "options": [
2038
+ "RunAllTestsInOrg",
2039
+ "RunLocalTests",
2040
+ "RunSpecifiedTests",
2041
+ "RunRelevantTests"
2042
+ ],
2043
+ "type": "option"
2044
+ },
2045
+ "verbose": {
2046
+ "exclusive": [
2047
+ "concise"
2048
+ ],
2049
+ "name": "verbose",
2050
+ "summary": "Show verbose output of the validation result.",
2051
+ "allowNo": false,
2052
+ "type": "boolean"
2053
+ },
2054
+ "wait": {
2055
+ "char": "w",
2056
+ "description": "If the command continues to run after the wait period, the CLI returns control of the terminal window to you and returns the job ID. To resume watching the validation, run \"<%= config.bin %> project deploy resume\". To check the status of the validation, run \"<%= config.bin %> project deploy report\".",
2057
+ "name": "wait",
2058
+ "summary": "Number of minutes to wait for the command to complete and display results.",
2059
+ "hasDynamicHelp": true,
2060
+ "helpValue": "<minutes>",
2061
+ "multiple": false,
2062
+ "type": "option"
2063
+ },
2064
+ "ignore-warnings": {
2065
+ "char": "g",
2066
+ "description": "If you specify this flag, and a warning occurs, the success status of the deployment is set to true. If you don't specify this flag, and a warning occurs, then the success status is set to false, and the warning is treated like an error.\n\nThis flag is useful in a CI environment and your deployment includes destructive changes; if you try to delete a component that doesn't exist in the org, you get a warning. In this case, to ensure that the command returns a success value of true, specify this flag.",
2067
+ "name": "ignore-warnings",
2068
+ "summary": "Ignore warnings and allow a deployment to complete successfully.",
2069
+ "allowNo": false,
2070
+ "type": "boolean"
2071
+ },
2072
+ "coverage-formatters": {
2073
+ "description": "For multiple formatters, repeat the flag for each formatter.\n--coverage-formatters lcov --coverage-formatters clover",
2074
+ "helpGroup": "Test",
2075
+ "name": "coverage-formatters",
2076
+ "summary": "Format of the code coverage results.",
2077
+ "hasDynamicHelp": false,
2078
+ "multiple": true,
2079
+ "options": [
2080
+ "clover",
2081
+ "cobertura",
2082
+ "html-spa",
2083
+ "html",
2084
+ "json",
2085
+ "json-summary",
2086
+ "lcovonly",
2087
+ "none",
2088
+ "teamcity",
2089
+ "text",
2090
+ "text-summary"
2091
+ ],
2092
+ "type": "option"
2093
+ },
2094
+ "junit": {
2095
+ "helpGroup": "Test",
2096
+ "name": "junit",
2097
+ "summary": "Output JUnit test results.",
2098
+ "allowNo": false,
2099
+ "type": "boolean"
2100
+ },
2101
+ "results-dir": {
2102
+ "helpGroup": "Test",
2103
+ "name": "results-dir",
2104
+ "relationships": [
2105
+ {
2106
+ "type": "some",
2107
+ "flags": [
2108
+ "coverage-formatters",
2109
+ "junit"
2110
+ ]
2111
+ }
2112
+ ],
2113
+ "summary": "Output directory for code coverage and JUnit results; defaults to the deploy ID.",
2114
+ "hasDynamicHelp": false,
2115
+ "multiple": false,
2116
+ "type": "option"
2117
+ },
2118
+ "purge-on-delete": {
2119
+ "dependsOn": [
2120
+ "manifest"
2121
+ ],
2122
+ "helpGroup": "Delete",
2123
+ "name": "purge-on-delete",
2124
+ "relationships": [
2125
+ {
2126
+ "type": "some",
2127
+ "flags": [
2128
+ "pre-destructive-changes",
2129
+ "post-destructive-changes"
2130
+ ]
2131
+ }
2132
+ ],
2133
+ "summary": "Specify that deleted components in the destructive changes manifest file are immediately eligible for deletion rather than being stored in the Recycle Bin.",
2134
+ "allowNo": false,
2135
+ "type": "boolean"
2136
+ },
2137
+ "pre-destructive-changes": {
2138
+ "dependsOn": [
2139
+ "manifest"
2140
+ ],
2141
+ "helpGroup": "Delete",
2142
+ "name": "pre-destructive-changes",
2143
+ "summary": "File path for a manifest (destructiveChangesPre.xml) of components to delete before the deploy",
2144
+ "hasDynamicHelp": false,
2145
+ "multiple": false,
2146
+ "type": "option"
2147
+ },
2148
+ "post-destructive-changes": {
2149
+ "dependsOn": [
2150
+ "manifest"
2151
+ ],
2152
+ "helpGroup": "Delete",
2153
+ "name": "post-destructive-changes",
2154
+ "summary": "File path for a manifest (destructiveChangesPost.xml) of components to delete after the deploy.",
2155
+ "hasDynamicHelp": false,
2156
+ "multiple": false,
2157
+ "type": "option"
2158
+ }
2199
2159
  },
2200
2160
  "hasDynamicHelp": true,
2201
2161
  "hiddenAliases": [],
2202
- "id": "project:delete:tracking",
2162
+ "id": "project:deploy:validate",
2203
2163
  "pluginAlias": "@salesforce/plugin-deploy-retrieve",
2204
2164
  "pluginName": "@salesforce/plugin-deploy-retrieve",
2205
2165
  "pluginType": "core",
2206
2166
  "strict": true,
2207
- "summary": "Delete all local source tracking information.",
2167
+ "summary": "Validate a metadata deployment without actually executing it.",
2208
2168
  "enableJsonFlag": true,
2209
- "requiresProject": true,
2169
+ "configurationVariablesSection": {
2170
+ "header": "CONFIGURATION VARIABLES",
2171
+ "body": [
2172
+ {
2173
+ "name": "target-org",
2174
+ "description": "Username or alias of the org that all commands run against by default. (sf only)"
2175
+ },
2176
+ {
2177
+ "name": "org-api-version",
2178
+ "description": "API version of your project. Default: API version of your Dev Hub org."
2179
+ }
2180
+ ]
2181
+ },
2182
+ "envVariablesSection": {
2183
+ "header": "ENVIRONMENT VARIABLES",
2184
+ "body": [
2185
+ {
2186
+ "name": "SF_TARGET_ORG",
2187
+ "description": "Username or alias of your default org. Overrides the target-org configuration variable."
2188
+ },
2189
+ {
2190
+ "name": "SF_USE_PROGRESS_BAR",
2191
+ "description": "Set to false to disable the progress bar when running the metadata deploy command."
2192
+ }
2193
+ ]
2194
+ },
2195
+ "errorCodes": {
2196
+ "header": "ERROR CODES",
2197
+ "body": [
2198
+ {
2199
+ "name": "Succeeded (0)",
2200
+ "description": "The deploy succeeded."
2201
+ },
2202
+ {
2203
+ "name": "Canceled (1)",
2204
+ "description": "The deploy was canceled."
2205
+ },
2206
+ {
2207
+ "name": "Failed (1)",
2208
+ "description": "The deploy failed."
2209
+ },
2210
+ {
2211
+ "name": "SucceededPartial (68)",
2212
+ "description": "The deploy partially succeeded."
2213
+ },
2214
+ {
2215
+ "name": "InProgress (69)",
2216
+ "description": "The deploy is in progress."
2217
+ },
2218
+ {
2219
+ "name": "Pending (69)",
2220
+ "description": "The deploy is pending."
2221
+ },
2222
+ {
2223
+ "name": "Canceling (69)",
2224
+ "description": "The deploy is being canceled."
2225
+ }
2226
+ ]
2227
+ },
2210
2228
  "isESM": true,
2211
2229
  "relativePath": [
2212
2230
  "lib",
2213
2231
  "commands",
2214
2232
  "project",
2215
- "delete",
2216
- "tracking.js"
2233
+ "deploy",
2234
+ "validate.js"
2217
2235
  ],
2218
2236
  "aliasPermutations": [
2219
- "force:source:tracking:clear",
2220
- "source:force:tracking:clear",
2221
- "source:tracking:force:clear",
2222
- "source:tracking:clear:force",
2223
- "force:tracking:source:clear",
2224
- "tracking:force:source:clear",
2225
- "tracking:source:force:clear",
2226
- "tracking:source:clear:force",
2227
- "force:tracking:clear:source",
2228
- "tracking:force:clear:source",
2229
- "tracking:clear:force:source",
2230
- "tracking:clear:source:force",
2231
- "force:source:clear:tracking",
2232
- "source:force:clear:tracking",
2233
- "source:clear:force:tracking",
2234
- "source:clear:tracking:force",
2235
- "force:clear:source:tracking",
2236
- "clear:force:source:tracking",
2237
- "clear:source:force:tracking",
2238
- "clear:source:tracking:force",
2239
- "force:clear:tracking:source",
2240
- "clear:force:tracking:source",
2241
- "clear:tracking:force:source",
2242
- "clear:tracking:source:force"
2237
+ "deploy:metadata:validate",
2238
+ "metadata:deploy:validate",
2239
+ "metadata:validate:deploy",
2240
+ "deploy:validate:metadata",
2241
+ "validate:deploy:metadata",
2242
+ "validate:metadata:deploy"
2243
2243
  ],
2244
2244
  "permutations": [
2245
- "project:delete:tracking",
2246
- "delete:project:tracking",
2247
- "delete:tracking:project",
2248
- "project:tracking:delete",
2249
- "tracking:project:delete",
2250
- "tracking:delete:project"
2245
+ "project:deploy:validate",
2246
+ "deploy:project:validate",
2247
+ "deploy:validate:project",
2248
+ "project:validate:deploy",
2249
+ "validate:project:deploy",
2250
+ "validate:deploy:project"
2251
2251
  ]
2252
2252
  },
2253
2253
  "project:generate:manifest": {
@@ -3054,5 +3054,5 @@
3054
3054
  ]
3055
3055
  }
3056
3056
  },
3057
- "version": "3.24.2"
3057
+ "version": "3.24.3"
3058
3058
  }