sfdx-hardis 6.17.1 → 6.17.2-alpha202512261505.0

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.
@@ -5924,6 +5924,121 @@
5924
5924
  "import:data:org:hardis"
5925
5925
  ]
5926
5926
  },
5927
+ "hardis:org:fix:listviewmine": {
5928
+ "aliases": [],
5929
+ "args": {},
5930
+ "description": "Fix listviews whose scope Mine has been replaced by Everything\n\n[![Invalid scope:Mine, not allowed ? Deploy your ListViews anyway !](https://github.com/hardisgroupcom/sfdx-hardis/raw/main/docs/assets/images/article-invalid-scope-mine.jpg)](https://nicolas.vuillamy.fr/invalid-scope-mine-not-allowed-deploy-your-listviews-anyway-443aceca8ac7)\n\nList of ListViews can be:\n\n- read from .sfdx-hardis.yml file in property **listViewsToSetToMine**\n- sent in argument listviews\n\nNote: property **listViewsToSetToMine** can be auto-generated by command hardis:work:save if .sfdx-hardis.yml contains the following configuration\n\n```yaml\nautoCleanTypes:\n - listViewsMine\n```\n\n- Example of sfdx-hardis.yml property `listViewsToSetToMine`:\n\n```yaml\nlistViewsToSetToMine:\n - \"force-app/main/default/objects/Operation__c/listViews/MyCurrentOperations.listView-meta.xml\"\n - \"force-app/main/default/objects/Operation__c/listViews/MyFinalizedOperations.listView-meta.xml\"\n - \"force-app/main/default/objects/Opportunity/listViews/Default_Opportunity_Pipeline.listView-meta.xml\"\n - \"force-app/main/default/objects/Opportunity/listViews/MyCurrentSubscriptions.listView-meta.xml\"\n - \"force-app/main/default/objects/Opportunity/listViews/MySubscriptions.listView-meta.xml\"\n - \"force-app/main/default/objects/Account/listViews/MyActivePartners.listView-meta.xml\"\n```\n\n- If manually written, this could also be:\n\n```yaml\nlistViewsToSetToMine:\n - \"Operation__c:MyCurrentOperations\"\n - \"Operation__c:MyFinalizedOperations\"\n - \"Opportunity:Default_Opportunity_Pipeline\"\n - \"Opportunity:MyCurrentSubscriptions\"\n - \"Opportunity:MySubscriptions\"\n - \"Account:MyActivePartners\"\n```\n\nTroubleshooting: if you need to run this command from an alpine-linux based docker image, use this workaround in your dockerfile:\n\n```dockerfile\n# Do not use puppeteer embedded chromium\nRUN apk add --update --no-cache chromium\nENV PUPPETEER_SKIP_CHROMIUM_DOWNLOAD=\"true\"\nENV CHROMIUM_PATH=\"/usr/bin/chromium-browser\"\nENV PUPPETEER_EXECUTABLE_PATH=\"$\\{CHROMIUM_PATH}\" // remove \\ before {\n```\n",
5931
+ "examples": [
5932
+ "$ sf hardis:org:fix:listviewmine",
5933
+ "$ sf hardis:org:fix:listviewmine --listviews Opportunity:MySubscriptions,Account:MyActivePartners"
5934
+ ],
5935
+ "flags": {
5936
+ "json": {
5937
+ "description": "Format output as json.",
5938
+ "helpGroup": "GLOBAL",
5939
+ "name": "json",
5940
+ "allowNo": false,
5941
+ "type": "boolean"
5942
+ },
5943
+ "flags-dir": {
5944
+ "helpGroup": "GLOBAL",
5945
+ "name": "flags-dir",
5946
+ "summary": "Import flag values from a directory.",
5947
+ "hasDynamicHelp": false,
5948
+ "multiple": false,
5949
+ "type": "option"
5950
+ },
5951
+ "listviews": {
5952
+ "char": "l",
5953
+ "description": "Comma-separated list of listviews following format Object:ListViewName\nExample: Contact:MyContacts,Contact:MyActiveContacts,Opportunity:MYClosedOpportunities",
5954
+ "name": "listviews",
5955
+ "hasDynamicHelp": false,
5956
+ "multiple": false,
5957
+ "type": "option"
5958
+ },
5959
+ "debug": {
5960
+ "char": "d",
5961
+ "description": "Activate debug mode (more logs)",
5962
+ "name": "debug",
5963
+ "allowNo": false,
5964
+ "type": "boolean"
5965
+ },
5966
+ "websocket": {
5967
+ "description": "Websocket host:port for VsCode SFDX Hardis UI integration",
5968
+ "name": "websocket",
5969
+ "hasDynamicHelp": false,
5970
+ "multiple": false,
5971
+ "type": "option"
5972
+ },
5973
+ "skipauth": {
5974
+ "description": "Skip authentication check when a default username is required",
5975
+ "name": "skipauth",
5976
+ "allowNo": false,
5977
+ "type": "boolean"
5978
+ },
5979
+ "target-org": {
5980
+ "aliases": [
5981
+ "targetusername",
5982
+ "u"
5983
+ ],
5984
+ "char": "o",
5985
+ "deprecateAliases": true,
5986
+ "name": "target-org",
5987
+ "noCacheDefault": true,
5988
+ "required": true,
5989
+ "summary": "Username or alias of the target org. Not required if the `target-org` configuration variable is already set.",
5990
+ "hasDynamicHelp": true,
5991
+ "multiple": false,
5992
+ "type": "option"
5993
+ }
5994
+ },
5995
+ "hasDynamicHelp": true,
5996
+ "hiddenAliases": [],
5997
+ "id": "hardis:org:fix:listviewmine",
5998
+ "pluginAlias": "sfdx-hardis",
5999
+ "pluginName": "sfdx-hardis",
6000
+ "pluginType": "core",
6001
+ "strict": true,
6002
+ "enableJsonFlag": true,
6003
+ "title": "Fix listviews with ",
6004
+ "requiresProject": true,
6005
+ "isESM": true,
6006
+ "relativePath": [
6007
+ "lib",
6008
+ "commands",
6009
+ "hardis",
6010
+ "org",
6011
+ "fix",
6012
+ "listviewmine.js"
6013
+ ],
6014
+ "aliasPermutations": [],
6015
+ "permutations": [
6016
+ "hardis:org:fix:listviewmine",
6017
+ "org:hardis:fix:listviewmine",
6018
+ "org:fix:hardis:listviewmine",
6019
+ "org:fix:listviewmine:hardis",
6020
+ "hardis:fix:org:listviewmine",
6021
+ "fix:hardis:org:listviewmine",
6022
+ "fix:org:hardis:listviewmine",
6023
+ "fix:org:listviewmine:hardis",
6024
+ "hardis:fix:listviewmine:org",
6025
+ "fix:hardis:listviewmine:org",
6026
+ "fix:listviewmine:hardis:org",
6027
+ "fix:listviewmine:org:hardis",
6028
+ "hardis:org:listviewmine:fix",
6029
+ "org:hardis:listviewmine:fix",
6030
+ "org:listviewmine:hardis:fix",
6031
+ "org:listviewmine:fix:hardis",
6032
+ "hardis:listviewmine:org:fix",
6033
+ "listviewmine:hardis:org:fix",
6034
+ "listviewmine:org:hardis:fix",
6035
+ "listviewmine:org:fix:hardis",
6036
+ "hardis:listviewmine:fix:org",
6037
+ "listviewmine:hardis:fix:org",
6038
+ "listviewmine:fix:hardis:org",
6039
+ "listviewmine:fix:org:hardis"
6040
+ ]
6041
+ },
5927
6042
  "hardis:org:diagnose:audittrail": {
5928
6043
  "aliases": [],
5929
6044
  "args": {},
@@ -7591,121 +7706,6 @@
7591
7706
  "import:files:org:hardis"
7592
7707
  ]
7593
7708
  },
7594
- "hardis:org:fix:listviewmine": {
7595
- "aliases": [],
7596
- "args": {},
7597
- "description": "Fix listviews whose scope Mine has been replaced by Everything\n\n[![Invalid scope:Mine, not allowed ? Deploy your ListViews anyway !](https://github.com/hardisgroupcom/sfdx-hardis/raw/main/docs/assets/images/article-invalid-scope-mine.jpg)](https://nicolas.vuillamy.fr/invalid-scope-mine-not-allowed-deploy-your-listviews-anyway-443aceca8ac7)\n\nList of ListViews can be:\n\n- read from .sfdx-hardis.yml file in property **listViewsToSetToMine**\n- sent in argument listviews\n\nNote: property **listViewsToSetToMine** can be auto-generated by command hardis:work:save if .sfdx-hardis.yml contains the following configuration\n\n```yaml\nautoCleanTypes:\n - listViewsMine\n```\n\n- Example of sfdx-hardis.yml property `listViewsToSetToMine`:\n\n```yaml\nlistViewsToSetToMine:\n - \"force-app/main/default/objects/Operation__c/listViews/MyCurrentOperations.listView-meta.xml\"\n - \"force-app/main/default/objects/Operation__c/listViews/MyFinalizedOperations.listView-meta.xml\"\n - \"force-app/main/default/objects/Opportunity/listViews/Default_Opportunity_Pipeline.listView-meta.xml\"\n - \"force-app/main/default/objects/Opportunity/listViews/MyCurrentSubscriptions.listView-meta.xml\"\n - \"force-app/main/default/objects/Opportunity/listViews/MySubscriptions.listView-meta.xml\"\n - \"force-app/main/default/objects/Account/listViews/MyActivePartners.listView-meta.xml\"\n```\n\n- If manually written, this could also be:\n\n```yaml\nlistViewsToSetToMine:\n - \"Operation__c:MyCurrentOperations\"\n - \"Operation__c:MyFinalizedOperations\"\n - \"Opportunity:Default_Opportunity_Pipeline\"\n - \"Opportunity:MyCurrentSubscriptions\"\n - \"Opportunity:MySubscriptions\"\n - \"Account:MyActivePartners\"\n```\n\nTroubleshooting: if you need to run this command from an alpine-linux based docker image, use this workaround in your dockerfile:\n\n```dockerfile\n# Do not use puppeteer embedded chromium\nRUN apk add --update --no-cache chromium\nENV PUPPETEER_SKIP_CHROMIUM_DOWNLOAD=\"true\"\nENV CHROMIUM_PATH=\"/usr/bin/chromium-browser\"\nENV PUPPETEER_EXECUTABLE_PATH=\"$\\{CHROMIUM_PATH}\" // remove \\ before {\n```\n",
7598
- "examples": [
7599
- "$ sf hardis:org:fix:listviewmine",
7600
- "$ sf hardis:org:fix:listviewmine --listviews Opportunity:MySubscriptions,Account:MyActivePartners"
7601
- ],
7602
- "flags": {
7603
- "json": {
7604
- "description": "Format output as json.",
7605
- "helpGroup": "GLOBAL",
7606
- "name": "json",
7607
- "allowNo": false,
7608
- "type": "boolean"
7609
- },
7610
- "flags-dir": {
7611
- "helpGroup": "GLOBAL",
7612
- "name": "flags-dir",
7613
- "summary": "Import flag values from a directory.",
7614
- "hasDynamicHelp": false,
7615
- "multiple": false,
7616
- "type": "option"
7617
- },
7618
- "listviews": {
7619
- "char": "l",
7620
- "description": "Comma-separated list of listviews following format Object:ListViewName\nExample: Contact:MyContacts,Contact:MyActiveContacts,Opportunity:MYClosedOpportunities",
7621
- "name": "listviews",
7622
- "hasDynamicHelp": false,
7623
- "multiple": false,
7624
- "type": "option"
7625
- },
7626
- "debug": {
7627
- "char": "d",
7628
- "description": "Activate debug mode (more logs)",
7629
- "name": "debug",
7630
- "allowNo": false,
7631
- "type": "boolean"
7632
- },
7633
- "websocket": {
7634
- "description": "Websocket host:port for VsCode SFDX Hardis UI integration",
7635
- "name": "websocket",
7636
- "hasDynamicHelp": false,
7637
- "multiple": false,
7638
- "type": "option"
7639
- },
7640
- "skipauth": {
7641
- "description": "Skip authentication check when a default username is required",
7642
- "name": "skipauth",
7643
- "allowNo": false,
7644
- "type": "boolean"
7645
- },
7646
- "target-org": {
7647
- "aliases": [
7648
- "targetusername",
7649
- "u"
7650
- ],
7651
- "char": "o",
7652
- "deprecateAliases": true,
7653
- "name": "target-org",
7654
- "noCacheDefault": true,
7655
- "required": true,
7656
- "summary": "Username or alias of the target org. Not required if the `target-org` configuration variable is already set.",
7657
- "hasDynamicHelp": true,
7658
- "multiple": false,
7659
- "type": "option"
7660
- }
7661
- },
7662
- "hasDynamicHelp": true,
7663
- "hiddenAliases": [],
7664
- "id": "hardis:org:fix:listviewmine",
7665
- "pluginAlias": "sfdx-hardis",
7666
- "pluginName": "sfdx-hardis",
7667
- "pluginType": "core",
7668
- "strict": true,
7669
- "enableJsonFlag": true,
7670
- "title": "Fix listviews with ",
7671
- "requiresProject": true,
7672
- "isESM": true,
7673
- "relativePath": [
7674
- "lib",
7675
- "commands",
7676
- "hardis",
7677
- "org",
7678
- "fix",
7679
- "listviewmine.js"
7680
- ],
7681
- "aliasPermutations": [],
7682
- "permutations": [
7683
- "hardis:org:fix:listviewmine",
7684
- "org:hardis:fix:listviewmine",
7685
- "org:fix:hardis:listviewmine",
7686
- "org:fix:listviewmine:hardis",
7687
- "hardis:fix:org:listviewmine",
7688
- "fix:hardis:org:listviewmine",
7689
- "fix:org:hardis:listviewmine",
7690
- "fix:org:listviewmine:hardis",
7691
- "hardis:fix:listviewmine:org",
7692
- "fix:hardis:listviewmine:org",
7693
- "fix:listviewmine:hardis:org",
7694
- "fix:listviewmine:org:hardis",
7695
- "hardis:org:listviewmine:fix",
7696
- "org:hardis:listviewmine:fix",
7697
- "org:listviewmine:hardis:fix",
7698
- "org:listviewmine:fix:hardis",
7699
- "hardis:listviewmine:org:fix",
7700
- "listviewmine:hardis:org:fix",
7701
- "listviewmine:org:hardis:fix",
7702
- "listviewmine:org:fix:hardis",
7703
- "hardis:listviewmine:fix:org",
7704
- "listviewmine:hardis:fix:org",
7705
- "listviewmine:fix:hardis:org",
7706
- "listviewmine:fix:org:hardis"
7707
- ]
7708
- },
7709
7709
  "hardis:org:generate:packagexmlfull": {
7710
7710
  "aliases": [],
7711
7711
  "args": {},
@@ -10324,12 +10324,12 @@
10324
10324
  "remotesites:audit:project:hardis"
10325
10325
  ]
10326
10326
  },
10327
- "hardis:project:clean:emptyitems": {
10327
+ "hardis:project:configure:auth": {
10328
10328
  "aliases": [],
10329
10329
  "args": {},
10330
- "description": "\n## Command Behavior\n\n**Removes empty or irrelevant metadata items from your Salesforce DX project sources.**\n\nThis command helps maintain a clean and efficient Salesforce codebase by deleting metadata files that are essentially empty or contain no meaningful configuration. These files can sometimes be generated during retrieval processes or remain after refactoring, contributing to unnecessary clutter in your project.\n\nKey functionalities:\n\n- **Targeted Cleaning:** Specifically targets and removes empty instances of:\n - Global Value Set Translations (`.globalValueSetTranslation-meta.xml`)\n - Standard Value Sets (`.standardValueSet-meta.xml`)\n - Sharing Rules (`.sharingRules-meta.xml`)\n- **Content-Based Deletion:** It checks the XML content of these files for the presence of specific tags (e.g., `valueTranslation` for Global Value Set Translations) to determine if they are truly empty or lack relevant data.\n\n<details markdown=\"1\">\n<summary>Technical explanations</summary>\n\nThe command's technical implementation involves:\n\n- **File Discovery:** Uses `glob` to find files matching predefined patterns for Global Value Set Translations, Standard Value Sets, and Sharing Rules within the specified root folder (defaults to `force-app`).\n- **XML Parsing:** For each matching file, it reads and parses the XML content using `parseXmlFile`.\n- **Content Validation:** It then checks the parsed XML object for the existence of specific nested properties (e.g., `xmlContent.GlobalValueSetTranslation.valueTranslation`). If these properties are missing or empty, the file is considered empty.\n- **File Deletion:** If a file is determined to be empty, it is removed from the file system using `fs.remove`.\n- **Logging:** Provides clear messages about which files are being removed and a summary of the total number of items cleaned.\n</details>\n",
10330
+ "description": "\n## Command Behavior\n\n**Configures authentication between a Git branch and a target Salesforce org for CI/CD deployments.**\n\nThis command facilitates the setup of automated CI/CD pipelines, enabling seamless deployments from specific Git branches to designated Salesforce orgs. It supports both standard Salesforce orgs and Dev Hub configurations, catering to various enterprise deployment workflows.\n\nKey functionalities include:\n\n- **Org Selection/Login:** Guides the user to select an existing Salesforce org or log in to a new one.\n- **Git Branch Association:** Allows associating a specific Git branch with the chosen Salesforce org.\n- **Merge Target Definition:** Enables defining target Git branches into which the configured branch can merge, ensuring controlled deployment flows.\n- **Salesforce Username Configuration:** Prompts for the Salesforce username to be used by the CI server for deployments.\n- **SSL Certificate Generation:** Automatically generates an SSL certificate for secure authentication.\n\n<details markdown=\"1\">\n<summary>Technical explanations</summary>\n\nThe command's implementation involves several key technical aspects:\n\n- **SF CLI Integration:** Utilizes \n@salesforce/sf-plugins-core\n for command structure and flag parsing.\n- **Interactive Prompts:** Employs the \nprompts\n library for interactive user input, guiding the configuration process.\n- **Git Integration:** Interacts with Git to retrieve branch information using \n`git().branch([\"--list\", \"-r\"])`\n.\n- **Configuration Management:** Leverages internal utilities (`checkConfig`, `getConfig`, `setConfig`, `setInConfigFile`) to read from and write to project-specific configuration files (e.g., `.sfdx-hardis.<branchName>.yml`).\n- **Salesforce CLI Execution:** Executes Salesforce CLI commands programmatically via `execSfdxJson` for org interactions.\n- **SSL Certificate Generation:** Calls `generateSSLCertificate` to create necessary SSL certificates for JWT-based authentication.\n- **WebSocket Communication:** Uses `WebSocketClient` for potential communication with external tools or processes, such as restarting the command in VS Code.\n- **Dependency Check:** Ensures the presence of `openssl` on the system, which is required for SSL certificate generation.\n",
10331
10331
  "examples": [
10332
- "$ sf hardis:project:clean:emptyitems"
10332
+ "$ sf hardis:project:configure:auth"
10333
10333
  ],
10334
10334
  "flags": {
10335
10335
  "json": {
@@ -10347,14 +10347,12 @@
10347
10347
  "multiple": false,
10348
10348
  "type": "option"
10349
10349
  },
10350
- "folder": {
10351
- "char": "f",
10352
- "description": "Root folder",
10353
- "name": "folder",
10354
- "default": "force-app",
10355
- "hasDynamicHelp": false,
10356
- "multiple": false,
10357
- "type": "option"
10350
+ "devhub": {
10351
+ "char": "b",
10352
+ "description": "Configure project DevHub",
10353
+ "name": "devhub",
10354
+ "allowNo": false,
10355
+ "type": "boolean"
10358
10356
  },
10359
10357
  "debug": {
10360
10358
  "char": "d",
@@ -10375,12 +10373,246 @@
10375
10373
  "name": "skipauth",
10376
10374
  "allowNo": false,
10377
10375
  "type": "boolean"
10378
- }
10379
- },
10380
- "hasDynamicHelp": false,
10381
- "hiddenAliases": [],
10382
- "id": "hardis:project:clean:emptyitems",
10383
- "pluginAlias": "sfdx-hardis",
10376
+ },
10377
+ "target-org": {
10378
+ "aliases": [
10379
+ "targetusername",
10380
+ "u"
10381
+ ],
10382
+ "char": "o",
10383
+ "deprecateAliases": true,
10384
+ "name": "target-org",
10385
+ "noCacheDefault": true,
10386
+ "summary": "Username or alias of the target org.",
10387
+ "hasDynamicHelp": true,
10388
+ "multiple": false,
10389
+ "type": "option"
10390
+ },
10391
+ "target-dev-hub": {
10392
+ "aliases": [
10393
+ "targetdevhubusername"
10394
+ ],
10395
+ "char": "v",
10396
+ "deprecateAliases": true,
10397
+ "name": "target-dev-hub",
10398
+ "noCacheDefault": true,
10399
+ "required": false,
10400
+ "summary": "Username or alias of the Dev Hub org.",
10401
+ "hasDynamicHelp": true,
10402
+ "multiple": false,
10403
+ "type": "option"
10404
+ }
10405
+ },
10406
+ "hasDynamicHelp": true,
10407
+ "hiddenAliases": [],
10408
+ "id": "hardis:project:configure:auth",
10409
+ "pluginAlias": "sfdx-hardis",
10410
+ "pluginName": "sfdx-hardis",
10411
+ "pluginType": "core",
10412
+ "strict": true,
10413
+ "enableJsonFlag": true,
10414
+ "title": "Configure authentication",
10415
+ "requiresProject": false,
10416
+ "requiresDependencies": [
10417
+ "openssl"
10418
+ ],
10419
+ "isESM": true,
10420
+ "relativePath": [
10421
+ "lib",
10422
+ "commands",
10423
+ "hardis",
10424
+ "project",
10425
+ "configure",
10426
+ "auth.js"
10427
+ ],
10428
+ "aliasPermutations": [],
10429
+ "permutations": [
10430
+ "hardis:project:configure:auth",
10431
+ "project:hardis:configure:auth",
10432
+ "project:configure:hardis:auth",
10433
+ "project:configure:auth:hardis",
10434
+ "hardis:configure:project:auth",
10435
+ "configure:hardis:project:auth",
10436
+ "configure:project:hardis:auth",
10437
+ "configure:project:auth:hardis",
10438
+ "hardis:configure:auth:project",
10439
+ "configure:hardis:auth:project",
10440
+ "configure:auth:hardis:project",
10441
+ "configure:auth:project:hardis",
10442
+ "hardis:project:auth:configure",
10443
+ "project:hardis:auth:configure",
10444
+ "project:auth:hardis:configure",
10445
+ "project:auth:configure:hardis",
10446
+ "hardis:auth:project:configure",
10447
+ "auth:hardis:project:configure",
10448
+ "auth:project:hardis:configure",
10449
+ "auth:project:configure:hardis",
10450
+ "hardis:auth:configure:project",
10451
+ "auth:hardis:configure:project",
10452
+ "auth:configure:hardis:project",
10453
+ "auth:configure:project:hardis"
10454
+ ]
10455
+ },
10456
+ "hardis:project:convert:profilestopermsets": {
10457
+ "aliases": [],
10458
+ "args": {},
10459
+ "description": "\n## Command Behavior\n\n**Converts existing Salesforce Profiles into Permission Sets, facilitating a more granular and recommended security model.**\n\nThis command helps in migrating permissions from Profiles to Permission Sets, which is a best practice for managing user access in Salesforce. It creates a new Permission Set for each specified Profile, adopting a naming convention of `PS_PROFILENAME`.\n\nKey functionalities:\n\n- **Profile to Permission Set Conversion:** Automatically extracts permissions from a Profile and creates a corresponding Permission Set.\n- **Naming Convention:** New Permission Sets are named with a `PS_` prefix followed by the Profile name (e.g., `PS_Standard_User`).\n- **Exclusion Filter:** Allows you to exclude specific Profiles from the conversion process using the `--except` flag.\n\n<details markdown=\"1\">\n<summary>Technical explanations</summary>\n\nThe command's technical implementation involves:\n\n- **External Plugin Integration:** It relies on the `shane-sfdx-plugins` (specifically the `sf shane:profile:convert` command) to perform the actual conversion.\n- **File System Scan:** It reads the contents of the `force-app/main/default/profiles` directory to identify all available Profile metadata files.\n- **Command Execution:** For each identified Profile (that is not excluded), it constructs and executes the `sf shane:profile:convert` command with the appropriate Profile name and desired Permission Set name.\n- **Error Handling:** Includes basic error handling for the external command execution.\n</details>\n",
10460
+ "examples": [
10461
+ "$ sf hardis:project:convert:profilestopermsets"
10462
+ ],
10463
+ "flags": {
10464
+ "json": {
10465
+ "description": "Format output as json.",
10466
+ "helpGroup": "GLOBAL",
10467
+ "name": "json",
10468
+ "allowNo": false,
10469
+ "type": "boolean"
10470
+ },
10471
+ "flags-dir": {
10472
+ "helpGroup": "GLOBAL",
10473
+ "name": "flags-dir",
10474
+ "summary": "Import flag values from a directory.",
10475
+ "hasDynamicHelp": false,
10476
+ "multiple": false,
10477
+ "type": "option"
10478
+ },
10479
+ "except": {
10480
+ "char": "e",
10481
+ "description": "List of filters",
10482
+ "name": "except",
10483
+ "default": [],
10484
+ "hasDynamicHelp": false,
10485
+ "multiple": true,
10486
+ "type": "option"
10487
+ },
10488
+ "debug": {
10489
+ "char": "d",
10490
+ "description": "Activate debug mode (more logs)",
10491
+ "name": "debug",
10492
+ "allowNo": false,
10493
+ "type": "boolean"
10494
+ },
10495
+ "websocket": {
10496
+ "description": "Websocket host:port for VsCode SFDX Hardis UI integration",
10497
+ "name": "websocket",
10498
+ "hasDynamicHelp": false,
10499
+ "multiple": false,
10500
+ "type": "option"
10501
+ },
10502
+ "skipauth": {
10503
+ "description": "Skip authentication check when a default username is required",
10504
+ "name": "skipauth",
10505
+ "allowNo": false,
10506
+ "type": "boolean"
10507
+ }
10508
+ },
10509
+ "hasDynamicHelp": false,
10510
+ "hiddenAliases": [],
10511
+ "id": "hardis:project:convert:profilestopermsets",
10512
+ "pluginAlias": "sfdx-hardis",
10513
+ "pluginName": "sfdx-hardis",
10514
+ "pluginType": "core",
10515
+ "strict": true,
10516
+ "enableJsonFlag": true,
10517
+ "title": "Convert Profiles into Permission Sets",
10518
+ "requiresProject": true,
10519
+ "requiresSfdxPlugins": [
10520
+ "shane-sfdx-plugins"
10521
+ ],
10522
+ "isESM": true,
10523
+ "relativePath": [
10524
+ "lib",
10525
+ "commands",
10526
+ "hardis",
10527
+ "project",
10528
+ "convert",
10529
+ "profilestopermsets.js"
10530
+ ],
10531
+ "aliasPermutations": [],
10532
+ "permutations": [
10533
+ "hardis:project:convert:profilestopermsets",
10534
+ "project:hardis:convert:profilestopermsets",
10535
+ "project:convert:hardis:profilestopermsets",
10536
+ "project:convert:profilestopermsets:hardis",
10537
+ "hardis:convert:project:profilestopermsets",
10538
+ "convert:hardis:project:profilestopermsets",
10539
+ "convert:project:hardis:profilestopermsets",
10540
+ "convert:project:profilestopermsets:hardis",
10541
+ "hardis:convert:profilestopermsets:project",
10542
+ "convert:hardis:profilestopermsets:project",
10543
+ "convert:profilestopermsets:hardis:project",
10544
+ "convert:profilestopermsets:project:hardis",
10545
+ "hardis:project:profilestopermsets:convert",
10546
+ "project:hardis:profilestopermsets:convert",
10547
+ "project:profilestopermsets:hardis:convert",
10548
+ "project:profilestopermsets:convert:hardis",
10549
+ "hardis:profilestopermsets:project:convert",
10550
+ "profilestopermsets:hardis:project:convert",
10551
+ "profilestopermsets:project:hardis:convert",
10552
+ "profilestopermsets:project:convert:hardis",
10553
+ "hardis:profilestopermsets:convert:project",
10554
+ "profilestopermsets:hardis:convert:project",
10555
+ "profilestopermsets:convert:hardis:project",
10556
+ "profilestopermsets:convert:project:hardis"
10557
+ ]
10558
+ },
10559
+ "hardis:project:clean:emptyitems": {
10560
+ "aliases": [],
10561
+ "args": {},
10562
+ "description": "\n## Command Behavior\n\n**Removes empty or irrelevant metadata items from your Salesforce DX project sources.**\n\nThis command helps maintain a clean and efficient Salesforce codebase by deleting metadata files that are essentially empty or contain no meaningful configuration. These files can sometimes be generated during retrieval processes or remain after refactoring, contributing to unnecessary clutter in your project.\n\nKey functionalities:\n\n- **Targeted Cleaning:** Specifically targets and removes empty instances of:\n - Global Value Set Translations (`.globalValueSetTranslation-meta.xml`)\n - Standard Value Sets (`.standardValueSet-meta.xml`)\n - Sharing Rules (`.sharingRules-meta.xml`)\n- **Content-Based Deletion:** It checks the XML content of these files for the presence of specific tags (e.g., `valueTranslation` for Global Value Set Translations) to determine if they are truly empty or lack relevant data.\n\n<details markdown=\"1\">\n<summary>Technical explanations</summary>\n\nThe command's technical implementation involves:\n\n- **File Discovery:** Uses `glob` to find files matching predefined patterns for Global Value Set Translations, Standard Value Sets, and Sharing Rules within the specified root folder (defaults to `force-app`).\n- **XML Parsing:** For each matching file, it reads and parses the XML content using `parseXmlFile`.\n- **Content Validation:** It then checks the parsed XML object for the existence of specific nested properties (e.g., `xmlContent.GlobalValueSetTranslation.valueTranslation`). If these properties are missing or empty, the file is considered empty.\n- **File Deletion:** If a file is determined to be empty, it is removed from the file system using `fs.remove`.\n- **Logging:** Provides clear messages about which files are being removed and a summary of the total number of items cleaned.\n</details>\n",
10563
+ "examples": [
10564
+ "$ sf hardis:project:clean:emptyitems"
10565
+ ],
10566
+ "flags": {
10567
+ "json": {
10568
+ "description": "Format output as json.",
10569
+ "helpGroup": "GLOBAL",
10570
+ "name": "json",
10571
+ "allowNo": false,
10572
+ "type": "boolean"
10573
+ },
10574
+ "flags-dir": {
10575
+ "helpGroup": "GLOBAL",
10576
+ "name": "flags-dir",
10577
+ "summary": "Import flag values from a directory.",
10578
+ "hasDynamicHelp": false,
10579
+ "multiple": false,
10580
+ "type": "option"
10581
+ },
10582
+ "folder": {
10583
+ "char": "f",
10584
+ "description": "Root folder",
10585
+ "name": "folder",
10586
+ "default": "force-app",
10587
+ "hasDynamicHelp": false,
10588
+ "multiple": false,
10589
+ "type": "option"
10590
+ },
10591
+ "debug": {
10592
+ "char": "d",
10593
+ "description": "Activate debug mode (more logs)",
10594
+ "name": "debug",
10595
+ "allowNo": false,
10596
+ "type": "boolean"
10597
+ },
10598
+ "websocket": {
10599
+ "description": "Websocket host:port for VsCode SFDX Hardis UI integration",
10600
+ "name": "websocket",
10601
+ "hasDynamicHelp": false,
10602
+ "multiple": false,
10603
+ "type": "option"
10604
+ },
10605
+ "skipauth": {
10606
+ "description": "Skip authentication check when a default username is required",
10607
+ "name": "skipauth",
10608
+ "allowNo": false,
10609
+ "type": "boolean"
10610
+ }
10611
+ },
10612
+ "hasDynamicHelp": false,
10613
+ "hiddenAliases": [],
10614
+ "id": "hardis:project:clean:emptyitems",
10615
+ "pluginAlias": "sfdx-hardis",
10384
10616
  "pluginName": "sfdx-hardis",
10385
10617
  "pluginType": "core",
10386
10618
  "strict": true,
@@ -11910,12 +12142,12 @@
11910
12142
  "xml:clean:project:hardis"
11911
12143
  ]
11912
12144
  },
11913
- "hardis:project:configure:auth": {
12145
+ "hardis:project:fix:profiletabs": {
11914
12146
  "aliases": [],
11915
12147
  "args": {},
11916
- "description": "\n## Command Behavior\n\n**Configures authentication between a Git branch and a target Salesforce org for CI/CD deployments.**\n\nThis command facilitates the setup of automated CI/CD pipelines, enabling seamless deployments from specific Git branches to designated Salesforce orgs. It supports both standard Salesforce orgs and Dev Hub configurations, catering to various enterprise deployment workflows.\n\nKey functionalities include:\n\n- **Org Selection/Login:** Guides the user to select an existing Salesforce org or log in to a new one.\n- **Git Branch Association:** Allows associating a specific Git branch with the chosen Salesforce org.\n- **Merge Target Definition:** Enables defining target Git branches into which the configured branch can merge, ensuring controlled deployment flows.\n- **Salesforce Username Configuration:** Prompts for the Salesforce username to be used by the CI server for deployments.\n- **SSL Certificate Generation:** Automatically generates an SSL certificate for secure authentication.\n\n<details markdown=\"1\">\n<summary>Technical explanations</summary>\n\nThe command's implementation involves several key technical aspects:\n\n- **SF CLI Integration:** Utilizes \n@salesforce/sf-plugins-core\n for command structure and flag parsing.\n- **Interactive Prompts:** Employs the \nprompts\n library for interactive user input, guiding the configuration process.\n- **Git Integration:** Interacts with Git to retrieve branch information using \n`git().branch([\"--list\", \"-r\"])`\n.\n- **Configuration Management:** Leverages internal utilities (`checkConfig`, `getConfig`, `setConfig`, `setInConfigFile`) to read from and write to project-specific configuration files (e.g., `.sfdx-hardis.<branchName>.yml`).\n- **Salesforce CLI Execution:** Executes Salesforce CLI commands programmatically via `execSfdxJson` for org interactions.\n- **SSL Certificate Generation:** Calls `generateSSLCertificate` to create necessary SSL certificates for JWT-based authentication.\n- **WebSocket Communication:** Uses `WebSocketClient` for potential communication with external tools or processes, such as restarting the command in VS Code.\n- **Dependency Check:** Ensures the presence of `openssl` on the system, which is required for SSL certificate generation.\n",
12148
+ "description": "\n## Command Behavior\n\n**Interactively updates tab visibility settings in Salesforce profiles, addressing a common issue where tab visibilities are not correctly retrieved by `sf project retrieve start`.**\n\nThis command provides a user-friendly interface to manage tab settings within your profile XML files, ensuring that your local project accurately reflects the intended tab configurations in your Salesforce org.\n\nKey functionalities:\n\n- **Interactive Tab Selection:** Displays a multi-select menu of all available tabs in your org, allowing you to choose which tabs to update.\n- **Visibility Control:** Lets you set the visibility for the selected tabs to either `DefaultOn` (Visible) or `Hidden`.\n- **Profile Selection:** Presents a multi-select menu of all .profile-meta.xml files in your project, allowing you to apply the tab visibility changes to specific profiles.\n- **XML Updates:** Modifies the <tabVisibilities> section of the selected profile XML files to reflect the chosen tab settings. If a tab visibility setting already exists for a selected tab, it will be updated; otherwise, a new one will be added.\n- **Sorted Output:** The <tabVisibilities> in the updated profile XML files are sorted alphabetically for consistency and readability.\n\n<details markdown=\"1\">\n<summary>Technical explanations</summary>\n\nThe command's technical implementation involves:\n\n- **SOQL Queries (Tooling API):** It queries the `TabDefinition` object using `soqlQueryTooling` to retrieve a list of all available tabs in the target org.\n- **File Discovery:** Uses `glob` to find all .profile-meta.xml files within the specified project path.\n- **Interactive Prompts:** Leverages the `prompts` library to create interactive menus for selecting tabs, visibility settings, and profiles.\n- **XML Parsing and Manipulation:** Uses `parseXmlFile` to read the content of profile XML files and `writeXmlFile` to write the modified content back. It manipulates the `tabVisibilities` array within the parsed XML to add or update tab settings.\n- **Array Sorting:** Employs the `sort-array` library to sort the `tabVisibilities` alphabetically by tab name.\n- **Logging:** Provides feedback to the user about which profiles have been updated and a summary of the changes.\n</details>\n",
11917
12149
  "examples": [
11918
- "$ sf hardis:project:configure:auth"
12150
+ "$ sf hardis:project:fix:profiletabs"
11919
12151
  ],
11920
12152
  "flags": {
11921
12153
  "json": {
@@ -11933,16 +12165,18 @@
11933
12165
  "multiple": false,
11934
12166
  "type": "option"
11935
12167
  },
11936
- "devhub": {
11937
- "char": "b",
11938
- "description": "Configure project DevHub",
11939
- "name": "devhub",
11940
- "allowNo": false,
11941
- "type": "boolean"
11942
- },
11943
- "debug": {
11944
- "char": "d",
11945
- "description": "Activate debug mode (more logs)",
12168
+ "path": {
12169
+ "char": "p",
12170
+ "description": "Root folder",
12171
+ "name": "path",
12172
+ "default": "/home/runner/work/sfdx-hardis/sfdx-hardis",
12173
+ "hasDynamicHelp": false,
12174
+ "multiple": false,
12175
+ "type": "option"
12176
+ },
12177
+ "debug": {
12178
+ "char": "d",
12179
+ "description": "Activate debug mode (more logs)",
11946
12180
  "name": "debug",
11947
12181
  "allowNo": false,
11948
12182
  "type": "boolean"
@@ -11969,21 +12203,8 @@
11969
12203
  "deprecateAliases": true,
11970
12204
  "name": "target-org",
11971
12205
  "noCacheDefault": true,
11972
- "summary": "Username or alias of the target org.",
11973
- "hasDynamicHelp": true,
11974
- "multiple": false,
11975
- "type": "option"
11976
- },
11977
- "target-dev-hub": {
11978
- "aliases": [
11979
- "targetdevhubusername"
11980
- ],
11981
- "char": "v",
11982
- "deprecateAliases": true,
11983
- "name": "target-dev-hub",
11984
- "noCacheDefault": true,
11985
- "required": false,
11986
- "summary": "Username or alias of the Dev Hub org.",
12206
+ "required": true,
12207
+ "summary": "Username or alias of the target org. Not required if the `target-org` configuration variable is already set.",
11987
12208
  "hasDynamicHelp": true,
11988
12209
  "multiple": false,
11989
12210
  "type": "option"
@@ -11991,60 +12212,57 @@
11991
12212
  },
11992
12213
  "hasDynamicHelp": true,
11993
12214
  "hiddenAliases": [],
11994
- "id": "hardis:project:configure:auth",
12215
+ "id": "hardis:project:fix:profiletabs",
11995
12216
  "pluginAlias": "sfdx-hardis",
11996
12217
  "pluginName": "sfdx-hardis",
11997
12218
  "pluginType": "core",
11998
12219
  "strict": true,
11999
12220
  "enableJsonFlag": true,
12000
- "title": "Configure authentication",
12001
- "requiresProject": false,
12002
- "requiresDependencies": [
12003
- "openssl"
12004
- ],
12221
+ "title": "Fix profiles to add tabs that are not retrieved by SF CLI",
12222
+ "requiresProject": true,
12005
12223
  "isESM": true,
12006
12224
  "relativePath": [
12007
12225
  "lib",
12008
12226
  "commands",
12009
12227
  "hardis",
12010
12228
  "project",
12011
- "configure",
12012
- "auth.js"
12229
+ "fix",
12230
+ "profiletabs.js"
12013
12231
  ],
12014
12232
  "aliasPermutations": [],
12015
12233
  "permutations": [
12016
- "hardis:project:configure:auth",
12017
- "project:hardis:configure:auth",
12018
- "project:configure:hardis:auth",
12019
- "project:configure:auth:hardis",
12020
- "hardis:configure:project:auth",
12021
- "configure:hardis:project:auth",
12022
- "configure:project:hardis:auth",
12023
- "configure:project:auth:hardis",
12024
- "hardis:configure:auth:project",
12025
- "configure:hardis:auth:project",
12026
- "configure:auth:hardis:project",
12027
- "configure:auth:project:hardis",
12028
- "hardis:project:auth:configure",
12029
- "project:hardis:auth:configure",
12030
- "project:auth:hardis:configure",
12031
- "project:auth:configure:hardis",
12032
- "hardis:auth:project:configure",
12033
- "auth:hardis:project:configure",
12034
- "auth:project:hardis:configure",
12035
- "auth:project:configure:hardis",
12036
- "hardis:auth:configure:project",
12037
- "auth:hardis:configure:project",
12038
- "auth:configure:hardis:project",
12039
- "auth:configure:project:hardis"
12234
+ "hardis:project:fix:profiletabs",
12235
+ "project:hardis:fix:profiletabs",
12236
+ "project:fix:hardis:profiletabs",
12237
+ "project:fix:profiletabs:hardis",
12238
+ "hardis:fix:project:profiletabs",
12239
+ "fix:hardis:project:profiletabs",
12240
+ "fix:project:hardis:profiletabs",
12241
+ "fix:project:profiletabs:hardis",
12242
+ "hardis:fix:profiletabs:project",
12243
+ "fix:hardis:profiletabs:project",
12244
+ "fix:profiletabs:hardis:project",
12245
+ "fix:profiletabs:project:hardis",
12246
+ "hardis:project:profiletabs:fix",
12247
+ "project:hardis:profiletabs:fix",
12248
+ "project:profiletabs:hardis:fix",
12249
+ "project:profiletabs:fix:hardis",
12250
+ "hardis:profiletabs:project:fix",
12251
+ "profiletabs:hardis:project:fix",
12252
+ "profiletabs:project:hardis:fix",
12253
+ "profiletabs:project:fix:hardis",
12254
+ "hardis:profiletabs:fix:project",
12255
+ "profiletabs:hardis:fix:project",
12256
+ "profiletabs:fix:hardis:project",
12257
+ "profiletabs:fix:project:hardis"
12040
12258
  ]
12041
12259
  },
12042
- "hardis:project:convert:profilestopermsets": {
12260
+ "hardis:project:fix:v53flexipages": {
12043
12261
  "aliases": [],
12044
12262
  "args": {},
12045
- "description": "\n## Command Behavior\n\n**Converts existing Salesforce Profiles into Permission Sets, facilitating a more granular and recommended security model.**\n\nThis command helps in migrating permissions from Profiles to Permission Sets, which is a best practice for managing user access in Salesforce. It creates a new Permission Set for each specified Profile, adopting a naming convention of `PS_PROFILENAME`.\n\nKey functionalities:\n\n- **Profile to Permission Set Conversion:** Automatically extracts permissions from a Profile and creates a corresponding Permission Set.\n- **Naming Convention:** New Permission Sets are named with a `PS_` prefix followed by the Profile name (e.g., `PS_Standard_User`).\n- **Exclusion Filter:** Allows you to exclude specific Profiles from the conversion process using the `--except` flag.\n\n<details markdown=\"1\">\n<summary>Technical explanations</summary>\n\nThe command's technical implementation involves:\n\n- **External Plugin Integration:** It relies on the `shane-sfdx-plugins` (specifically the `sf shane:profile:convert` command) to perform the actual conversion.\n- **File System Scan:** It reads the contents of the `force-app/main/default/profiles` directory to identify all available Profile metadata files.\n- **Command Execution:** For each identified Profile (that is not excluded), it constructs and executes the `sf shane:profile:convert` command with the appropriate Profile name and desired Permission Set name.\n- **Error Handling:** Includes basic error handling for the external command execution.\n</details>\n",
12263
+ "description": "\n## Command Behavior\n\n**Fixes Salesforce FlexiPages for compatibility with API Version 53.0 (Winter '22 release) by adding missing identifiers to component instances.**\n\nSalesforce introduced a change in API Version 53.0 that requires `identifier` tags within `componentInstance` and `fieldInstance` elements in FlexiPage metadata. If these identifiers are missing, deployments to orgs with API version 53.0 or higher will fail. This command automates the process of adding these missing identifiers, ensuring your FlexiPages remain deployable.\n\nKey functionalities:\n\n- **Targeted FlexiPage Processing:** Scans all .flexipage-meta.xml files within the specified root folder (defaults to current working directory).\n- **Identifier Injection:** Inserts a unique `identifier` tag (e.g., `SFDX_HARDIS_REPLACEMENT_ID`) into `componentInstance` and `fieldInstance` elements that lack one.\n\n**Important Note:** After running this command, ensure you update your `apiVersion` to `53.0` (or higher) in your `package.xml` and `sfdx-project.json` files.\n\n<details markdown=\"1\">\n<summary>Technical explanations</summary>\n\nThe command's technical implementation involves:\n\n- **File Discovery:** Uses `glob` to find all .flexipage-meta.xml files.\n- **Content Reading:** Reads the XML content of each FlexiPage file.\n- **Regular Expression Replacement:** Employs a set of regular expressions to identify specific XML patterns (componentName.../componentName.../componentInstance, componentName.../componentName.../visibilityRule, fieldItem.../fieldItem.../fieldInstance) that are missing the `identifier` tag.\n- **Dynamic ID Generation:** For each match, it generates a unique identifier (e.g., `sfdxHardisIdX`) and injects it into the XML structure.\n- **File Writing:** If changes are made, the modified XML content is written back to the FlexiPage file using `fs.writeFile`.\n- **Logging:** Provides messages about which FlexiPages are being processed and a summary of the total number of identifiers added.\n</details>\n",
12046
12264
  "examples": [
12047
- "$ sf hardis:project:convert:profilestopermsets"
12265
+ "$ sf hardis:project:fix:v53flexipages"
12048
12266
  ],
12049
12267
  "flags": {
12050
12268
  "json": {
@@ -12062,13 +12280,13 @@
12062
12280
  "multiple": false,
12063
12281
  "type": "option"
12064
12282
  },
12065
- "except": {
12066
- "char": "e",
12067
- "description": "List of filters",
12068
- "name": "except",
12069
- "default": [],
12283
+ "path": {
12284
+ "char": "p",
12285
+ "description": "Root folder",
12286
+ "name": "path",
12287
+ "default": "/home/runner/work/sfdx-hardis/sfdx-hardis",
12070
12288
  "hasDynamicHelp": false,
12071
- "multiple": true,
12289
+ "multiple": false,
12072
12290
  "type": "option"
12073
12291
  },
12074
12292
  "debug": {
@@ -12094,52 +12312,49 @@
12094
12312
  },
12095
12313
  "hasDynamicHelp": false,
12096
12314
  "hiddenAliases": [],
12097
- "id": "hardis:project:convert:profilestopermsets",
12315
+ "id": "hardis:project:fix:v53flexipages",
12098
12316
  "pluginAlias": "sfdx-hardis",
12099
12317
  "pluginName": "sfdx-hardis",
12100
12318
  "pluginType": "core",
12101
12319
  "strict": true,
12102
12320
  "enableJsonFlag": true,
12103
- "title": "Convert Profiles into Permission Sets",
12321
+ "title": "Fix flexipages for v53",
12104
12322
  "requiresProject": true,
12105
- "requiresSfdxPlugins": [
12106
- "shane-sfdx-plugins"
12107
- ],
12108
12323
  "isESM": true,
12109
12324
  "relativePath": [
12110
12325
  "lib",
12111
12326
  "commands",
12112
12327
  "hardis",
12113
12328
  "project",
12114
- "convert",
12115
- "profilestopermsets.js"
12329
+ "fix",
12330
+ "v53flexipages.js"
12116
12331
  ],
12117
12332
  "aliasPermutations": [],
12118
12333
  "permutations": [
12119
- "hardis:project:convert:profilestopermsets",
12120
- "project:hardis:convert:profilestopermsets",
12121
- "project:convert:hardis:profilestopermsets",
12122
- "project:convert:profilestopermsets:hardis",
12123
- "hardis:convert:project:profilestopermsets",
12124
- "convert:hardis:project:profilestopermsets",
12125
- "convert:project:hardis:profilestopermsets",
12126
- "convert:project:profilestopermsets:hardis",
12127
- "hardis:convert:profilestopermsets:project",
12128
- "convert:hardis:profilestopermsets:project",
12129
- "convert:profilestopermsets:hardis:project",
12130
- "convert:profilestopermsets:project:hardis",
12131
- "hardis:project:profilestopermsets:convert",
12132
- "project:hardis:profilestopermsets:convert",
12133
- "project:profilestopermsets:hardis:convert",
12134
- "project:profilestopermsets:convert:hardis",
12135
- "hardis:profilestopermsets:project:convert",
12136
- "profilestopermsets:hardis:project:convert",
12137
- "profilestopermsets:project:hardis:convert",
12138
- "profilestopermsets:project:convert:hardis",
12139
- "hardis:profilestopermsets:convert:project",
12140
- "profilestopermsets:hardis:convert:project",
12141
- "profilestopermsets:convert:hardis:project",
12142
- "profilestopermsets:convert:project:hardis"
12334
+ "hardis:project:fix:v53flexipages",
12335
+ "project:hardis:fix:v53flexipages",
12336
+ "project:fix:hardis:v53flexipages",
12337
+ "project:fix:v53flexipages:hardis",
12338
+ "hardis:fix:project:v53flexipages",
12339
+ "fix:hardis:project:v53flexipages",
12340
+ "fix:project:hardis:v53flexipages",
12341
+ "fix:project:v53flexipages:hardis",
12342
+ "hardis:fix:v53flexipages:project",
12343
+ "fix:hardis:v53flexipages:project",
12344
+ "fix:v53flexipages:hardis:project",
12345
+ "fix:v53flexipages:project:hardis",
12346
+ "hardis:project:v53flexipages:fix",
12347
+ "project:hardis:v53flexipages:fix",
12348
+ "project:v53flexipages:hardis:fix",
12349
+ "project:v53flexipages:fix:hardis",
12350
+ "hardis:v53flexipages:project:fix",
12351
+ "v53flexipages:hardis:project:fix",
12352
+ "v53flexipages:project:hardis:fix",
12353
+ "v53flexipages:project:fix:hardis",
12354
+ "hardis:v53flexipages:fix:project",
12355
+ "v53flexipages:hardis:fix:project",
12356
+ "v53flexipages:fix:hardis:project",
12357
+ "v53flexipages:fix:project:hardis"
12143
12358
  ]
12144
12359
  },
12145
12360
  "hardis:project:deploy:notify": {
@@ -12542,7 +12757,7 @@
12542
12757
  "hardis:project:deploy:sources:dx"
12543
12758
  ],
12544
12759
  "args": {},
12545
- "description": "Smart deploy of SFDX sources to target org, with many useful options.\n\nIn case of errors, [tips to fix them](https://sfdx-hardis.cloudity.com/deployTips/) will be included within the error messages.\n\n### Quick Deploy\n\nIn case Pull Request comments are configured on the project, Quick Deploy will try to be used (equivalent to button Quick Deploy)\n\nIf you do not want to use QuickDeploy, define variable `SFDX_HARDIS_QUICK_DEPLOY=false`\n\n- [GitHub Pull Requests comments config](https://sfdx-hardis.cloudity.com/salesforce-ci-cd-setup-integration-github/)\n- [Gitlab Merge requests notes config](https://sfdx-hardis.cloudity.com/salesforce-ci-cd-setup-integration-gitlab/)\n- [Azure Pull Requests comments config](https://sfdx-hardis.cloudity.com/salesforce-ci-cd-setup-integration-azure/)\n\n### Delta deployments\n\nTo activate delta deployments, define property `useDeltaDeployment: true` in `config/.sfdx-hardis.yml`.\n\nThis will activate delta deployments only between minor and major branches (major to major remains full deployment mode)\n\nIf you want to force the delta deployment into major orgs (ex: preprod to prod), this is not recommended but you can use env variable ALWAYS_ENABLE_DELTA_DEPLOYMENT=true\n\n### Smart Deployments Tests\n\nNot all metadata updates can break test classes, use Smart Deployment Tests to skip running test classes if ALL the following conditions are met:\n\n- Delta deployment is activated and applicable to the source and target branches\n- Delta deployed metadatas are all matching the list of **NOT_IMPACTING_METADATA_TYPES** (see below)\n- Target org is not a production org\n\nActivate Smart Deployment tests with:\n\n- env variable `USE_SMART_DEPLOYMENT_TESTS=true`\n- .sfdx-hardis.yml config property `useSmartDeploymentTests: true`\n\nDefaut list for **NOT_IMPACTING_METADATA_TYPES** (can be overridden with comma-separated list on env var NOT_IMPACTING_METADATA_TYPES)\n\n- Audience\n- AuraDefinitionBundle\n- Bot\n- BotVersion\n- ContentAsset\n- CustomObjectTranslation\n- CustomSite\n- CustomTab\n- Dashboard\n- ExperienceBundle\n- Flexipage\n- GlobalValueSetTranslation\n- Layout\n- LightningComponentBundle\n- NavigationMenu\n- ReportType\n- Report\n- SiteDotCom\n- StandardValueSetTranslation\n- StaticResource\n- Translations\n\nNote: if you want to disable Smart test classes for a PR, add **nosmart** in the text of the latest commit.\n\n### Dynamic deployment items / Overwrite management\n\nIf necessary,you can define the following files (that supports wildcards <members>*</members>):\n\n- `manifest/package-no-overwrite.xml`: Every element defined in this file will be deployed only if it is not existing yet in the target org (can be useful with ListView for example, if the client wants to update them directly in production org).\n - Can be overridden for a branch using .sfdx-hardis.yml property **packageNoOverwritePath** or environment variable PACKAGE_NO_OVERWRITE_PATH (for example, define: `packageNoOverwritePath: manifest/package-no-overwrite-main.xml` in config file `config/.sfdx-hardis.main.yml`)\n- `manifest/packageXmlOnChange.xml`: Every element defined in this file will not be deployed if it already has a similar definition in target org (can be useful for SharingRules for example)\n\nSee [Overwrite management documentation](https://sfdx-hardis.cloudity.com/salesforce-ci-cd-config-overwrite/)\n\n### Packages installation\n\nYou can define a list of package to install during deployments using property `installedPackages`\n\n- If `INSTALL_PACKAGES_DURING_CHECK_DEPLOY` is defined as `true` (or `installPackagesDuringCheckDeploy: true` in `.sfdx-hardis.yml`), packages will be installed even if the command is called with `--check` mode\n- You can automatically update this property by listing all packages installed on an org using command `sf hardis:org:retrieve:packageconfig`\n\nExample:\n\n```yaml\ninstalledPackages:\n - Id: 0A35r0000009EtECAU\n SubscriberPackageId: 033i0000000LVMYAA4\n SubscriberPackageName: Marketing Cloud\n SubscriberPackageNamespace: et4ae5\n SubscriberPackageVersionId: 04t6S000000l11iQAA\n SubscriberPackageVersionName: Marketing Cloud\n SubscriberPackageVersionNumber: 236.0.0.2\n installOnScratchOrgs: true // true or false depending you want to install this package when creating a new scratch org\n installDuringDeployments: true // set as true to install package during a deployment using sf hardis:project:deploy:smart\n installationkey: xxxxxxxxxxxxxxxxxxxx // if the package has a password, write it in this property\n - Id: 0A35r0000009F9CCAU\n SubscriberPackageId: 033b0000000Pf2AAAS\n SubscriberPackageName: Declarative Lookup Rollup Summaries Tool\n SubscriberPackageNamespace: dlrs\n SubscriberPackageVersionId: 04t5p000001BmLvAAK\n SubscriberPackageVersionName: Release\n SubscriberPackageVersionNumber: 2.15.0.9\n installOnScratchOrgs: true\n installDuringDeployments: true\n```\n\n### Deployment pre or post commands\n\nYou can define command lines to run before or after a deployment, with parameters:\n\n- **id**: Unique Id for the command\n- **label**: Human readable label for the command\n- **skipIfError**: If defined to \"true\", the post-command won't be run if there is a deployment failure\n- **context**: Defines the context where the command will be run. Can be **all** (default), **check-deployment-only** or **process-deployment-only**\n- **runOnlyOnceByOrg**: If set to true, the command will be run only one time per org. A record of SfdxHardisTrace__c is stored to make that possible (it needs to be existing in target org)\n\nIf the commands are not the same depending on the target org, you can define them into **config/branches/.sfdx-hardis-BRANCHNAME.yml** instead of root **config/.sfdx-hardis.yml**\n\nExample:\n\n```yaml\ncommandsPreDeploy:\n - id: knowledgeUnassign\n label: Remove KnowledgeUser right to the user who has it\n command: sf data update record --sobject User --where \"UserPermissionsKnowledgeUser='true'\" --values \"UserPermissionsKnowledgeUser='false'\" --json\n - id: knowledgeAssign\n label: Assign Knowledge user to the deployment user\n command: sf data update record --sobject User --where \"Username='deploy.github@myclient.com'\" --values \"UserPermissionsKnowledgeUser='true'\" --json\n\ncommandsPostDeploy:\n - id: knowledgeUnassign\n label: Remove KnowledgeUser right to the user who has it\n command: sf data update record --sobject User --where \"UserPermissionsKnowledgeUser='true'\" --values \"UserPermissionsKnowledgeUser='false'\" --json\n - id: knowledgeAssign\n label: Assign Knowledge user to desired username\n command: sf data update record --sobject User --where \"Username='admin-yser@myclient.com'\" --values \"UserPermissionsKnowledgeUser='true'\" --json\n - id: someActionToRunJustOneTime\n label: And to run only if deployment is success\n command: sf sfdmu:run ...\n skipIfError: true\n context: process-deployment-only\n runOnlyOnceByOrg: true\n```\n\n### Pull Requests Custom Behaviors\n\nIf some words are found **in the Pull Request description**, special behaviors will be applied\n\n| Word | Behavior |\n| :--- | :--- |\n| NO_DELTA | Even if delta deployments are activated, a deployment in mode **full** will be performed for this Pull Request |\n| PURGE_FLOW_VERSIONS | After deployment, inactive and obsolete Flow Versions will be deleted (equivalent to command sf hardis:org:purge:flow)<br/>**Caution: This will also purge active Flow Interviews !** |\n| DESTRUCTIVE_CHANGES_AFTER_DEPLOYMENT | If a file manifest/destructiveChanges.xml is found, it will be executed in a separate step, after the deployment of the main package |\n\n> For example, define `PURGE_FLOW_VERSIONS` and `DESTRUCTIVE_CHANGES_AFTER_DEPLOYMENT` in your Pull Request comments if you want to delete fields that are used in an active flow.\n\nNote: it is also possible to define these behaviors as ENV variables:\n\n- For all deployments (example: `PURGE_FLOW_VERSIONS=true`)\n- For a specific branch, by appending the target branch name (example: `PURGE_FLOW_VERSIONS_UAT=true`)\n\n### Deployment plan (deprecated)\n\nIf you need to deploy in multiple steps, you can define a property `deploymentPlan` in `.sfdx-hardis.yml`.\n\n- If a file `manifest/package.xml` is found, it will be placed with order 0 in the deployment plan\n\n- If a file `manifest/destructiveChanges.xml` is found, it will be executed as --postdestructivechanges\n\n- If env var `SFDX_HARDIS_DEPLOY_IGNORE_SPLIT_PACKAGES` is defined as `false` , split of package.xml will be applied\n\nExample:\n\n```yaml\ndeploymentPlan:\n packages:\n - label: Deploy Flow-Workflow\n packageXmlFile: manifest/splits/packageXmlFlowWorkflow.xml\n order: 6\n - label: Deploy SharingRules - Case\n packageXmlFile: manifest/splits/packageXmlSharingRulesCase.xml\n order: 30\n waitAfter: 30\n```\n\n### Automated fixes post deployments\n\n#### List view with scope Mine\n\nIf you defined a property **listViewsToSetToMine** in your .sfdx-hardis.yml, related ListViews will be set to Mine ( see command <https://sfdx-hardis.cloudity.com/hardis/org/fix/listviewmine/> )\n\nExample:\n\n```yaml\nlistViewsToSetToMine:\n - \"Operation__c:MyCurrentOperations\"\n - \"Operation__c:MyFinalizedOperations\"\n - \"Opportunity:Default_Opportunity_Pipeline\"\n - \"Opportunity:MyCurrentSubscriptions\"\n - \"Opportunity:MySubscriptions\"\n - \"Account:MyActivePartners\"\n```\n\nTroubleshooting: if you need to fix ListViews with mine from an alpine-linux based docker image, use this workaround in your dockerfile:\n\n```dockerfile\n# Do not use puppeteer embedded chromium\nRUN apk add --update --no-cache chromium\nENV PUPPETEER_SKIP_CHROMIUM_DOWNLOAD=\"true\"\nENV CHROMIUM_PATH=\"/usr/bin/chromium-browser\"\nENV PUPPETEER_EXECUTABLE_PATH=\"$\\{CHROMIUM_PATH}\" // remove \\ before {\n```\n\nIf you need to increase the deployment waiting time (sf project deploy start --wait arg), you can define env variable SFDX_DEPLOY_WAIT_MINUTES (default: 120)\n\nIf you need notifications to be sent using the current Pull Request and not the one just merged ([see use case](https://github.com/hardisgroupcom/sfdx-hardis/issues/637#issuecomment-2230798904)), define env variable SFDX_HARDIS_DEPLOY_BEFORE_MERGE=true\n\nIf you want to disable the calculation and display of Flow Visual Git Diff in Pull Request comments, define variable **SFDX_DISABLE_FLOW_DIFF=true**\n",
12760
+ "description": "Smart deploy of SFDX sources to target org, with many useful options.\n\nIn case of errors, [tips to fix them](https://sfdx-hardis.cloudity.com/deployTips/) will be included within the error messages.\n\n### Quick Deploy\n\nIn case Pull Request comments are configured on the project, Quick Deploy will try to be used (equivalent to button Quick Deploy)\n\nIf you do not want to use QuickDeploy, define variable `SFDX_HARDIS_QUICK_DEPLOY=false`\n\n- [GitHub Pull Requests comments config](https://sfdx-hardis.cloudity.com/salesforce-ci-cd-setup-integration-github/)\n- [Gitlab Merge requests notes config](https://sfdx-hardis.cloudity.com/salesforce-ci-cd-setup-integration-gitlab/)\n- [Azure Pull Requests comments config](https://sfdx-hardis.cloudity.com/salesforce-ci-cd-setup-integration-azure/)\n\n### Delta deployments\n\nTo activate delta deployments, define property `useDeltaDeployment: true` in `config/.sfdx-hardis.yml`.\n\nThis will activate delta deployments only between minor and major branches (major to major remains full deployment mode)\n\nIf you want to force the delta deployment into major orgs (ex: preprod to prod), this is not recommended but you can use env variable ALWAYS_ENABLE_DELTA_DEPLOYMENT=true\n\n### Smart Deployments Tests\n\nNot all metadata updates can break test classes, use Smart Deployment Tests to skip running test classes if ALL the following conditions are met:\n\n- Delta deployment is activated and applicable to the source and target branches\n- Delta deployed metadatas are all matching the list of **NOT_IMPACTING_METADATA_TYPES** (see below)\n- Target org is not a production org\n\nActivate Smart Deployment tests with:\n\n- env variable `USE_SMART_DEPLOYMENT_TESTS=true`\n- .sfdx-hardis.yml config property `useSmartDeploymentTests: true`\n\nDefaut list for **NOT_IMPACTING_METADATA_TYPES** (can be overridden with comma-separated list on env var NOT_IMPACTING_METADATA_TYPES)\n\n- Audience\n- AuraDefinitionBundle\n- Bot\n- BotVersion\n- ContentAsset\n- CustomObjectTranslation\n- CustomSite\n- CustomTab\n- Dashboard\n- ExperienceBundle\n- Flexipage\n- GlobalValueSetTranslation\n- Layout\n- LightningComponentBundle\n- NavigationMenu\n- ReportType\n- Report\n- SiteDotCom\n- StandardValueSetTranslation\n- StaticResource\n- Translations\n\nNote: if you want to disable Smart test classes for a PR, add **nosmart** in the text of the latest commit.\n\n### Custom Apex Test Classes (optional)\n\nYou can force Smart Deploy to run a specific list of Apex Test Classes. This is **not recommended** because best practice is to run all local tests. Enable it only if you have a specific need.\n\n- `enableDeploymentApexTestClasses` (boolean, default: false): Activate the custom list.\n- `deploymentApexTestClasses` (array of strings): The Apex Test Classes to run. Used only when the flag above is true.\n\nExample configuration in `config/.sfdx-hardis.yml` (can also be scoped to branches in `config/branches/.sfdx-hardis-BRANCHNAME.yml` or in Pull Request description):\n\n```yaml\nenableDeploymentApexTestClasses: true\ndeploymentApexTestClasses:\n - MyTestClass1\n - MyTestClass2\n```\n\n### Dynamic deployment items / Overwrite management\n\nIf necessary,you can define the following files (that supports wildcards <members>*</members>):\n\n- `manifest/package-no-overwrite.xml`: Every element defined in this file will be deployed only if it is not existing yet in the target org (can be useful with ListView for example, if the client wants to update them directly in production org).\n - Can be overridden for a branch using .sfdx-hardis.yml property **packageNoOverwritePath** or environment variable PACKAGE_NO_OVERWRITE_PATH (for example, define: `packageNoOverwritePath: manifest/package-no-overwrite-main.xml` in config file `config/.sfdx-hardis.main.yml`)\n- `manifest/packageXmlOnChange.xml`: Every element defined in this file will not be deployed if it already has a similar definition in target org (can be useful for SharingRules for example)\n\nSee [Overwrite management documentation](https://sfdx-hardis.cloudity.com/salesforce-ci-cd-config-overwrite/)\n\n### Packages installation\n\nYou can define a list of package to install during deployments using property `installedPackages`\n\n- If `INSTALL_PACKAGES_DURING_CHECK_DEPLOY` is defined as `true` (or `installPackagesDuringCheckDeploy: true` in `.sfdx-hardis.yml`), packages will be installed even if the command is called with `--check` mode\n- You can automatically update this property by listing all packages installed on an org using command `sf hardis:org:retrieve:packageconfig`\n\nExample:\n\n```yaml\ninstalledPackages:\n - Id: 0A35r0000009EtECAU\n SubscriberPackageId: 033i0000000LVMYAA4\n SubscriberPackageName: Marketing Cloud\n SubscriberPackageNamespace: et4ae5\n SubscriberPackageVersionId: 04t6S000000l11iQAA\n SubscriberPackageVersionName: Marketing Cloud\n SubscriberPackageVersionNumber: 236.0.0.2\n installOnScratchOrgs: true // true or false depending you want to install this package when creating a new scratch org\n installDuringDeployments: true // set as true to install package during a deployment using sf hardis:project:deploy:smart\n installationkey: xxxxxxxxxxxxxxxxxxxx // if the package has a password, write it in this property\n - Id: 0A35r0000009F9CCAU\n SubscriberPackageId: 033b0000000Pf2AAAS\n SubscriberPackageName: Declarative Lookup Rollup Summaries Tool\n SubscriberPackageNamespace: dlrs\n SubscriberPackageVersionId: 04t5p000001BmLvAAK\n SubscriberPackageVersionName: Release\n SubscriberPackageVersionNumber: 2.15.0.9\n installOnScratchOrgs: true\n installDuringDeployments: true\n```\n\n### Deployment pre or post commands\n\nYou can define command lines to run before or after a deployment, with parameters:\n\n- **id**: Unique Id for the command\n- **label**: Human readable label for the command\n- **skipIfError**: If defined to \"true\", the post-command won't be run if there is a deployment failure\n- **context**: Defines the context where the command will be run. Can be **all** (default), **check-deployment-only** or **process-deployment-only**\n- **runOnlyOnceByOrg**: If set to true, the command will be run only one time per org. A record of SfdxHardisTrace__c is stored to make that possible (it needs to be existing in target org)\n\nIf the commands are not the same depending on the target org, you can define them into **config/branches/.sfdx-hardis-BRANCHNAME.yml** instead of root **config/.sfdx-hardis.yml**\n\nExample:\n\n```yaml\ncommandsPreDeploy:\n - id: knowledgeUnassign\n label: Remove KnowledgeUser right to the user who has it\n command: sf data update record --sobject User --where \"UserPermissionsKnowledgeUser='true'\" --values \"UserPermissionsKnowledgeUser='false'\" --json\n - id: knowledgeAssign\n label: Assign Knowledge user to the deployment user\n command: sf data update record --sobject User --where \"Username='deploy.github@myclient.com'\" --values \"UserPermissionsKnowledgeUser='true'\" --json\n\ncommandsPostDeploy:\n - id: knowledgeUnassign\n label: Remove KnowledgeUser right to the user who has it\n command: sf data update record --sobject User --where \"UserPermissionsKnowledgeUser='true'\" --values \"UserPermissionsKnowledgeUser='false'\" --json\n - id: knowledgeAssign\n label: Assign Knowledge user to desired username\n command: sf data update record --sobject User --where \"Username='admin-yser@myclient.com'\" --values \"UserPermissionsKnowledgeUser='true'\" --json\n - id: someActionToRunJustOneTime\n label: And to run only if deployment is success\n command: sf sfdmu:run ...\n skipIfError: true\n context: process-deployment-only\n runOnlyOnceByOrg: true\n```\n\n### Pull Requests Custom Behaviors\n\nIf some words are found **in the Pull Request description**, special behaviors will be applied\n\n| Word | Behavior |\n| :--- | :--- |\n| NO_DELTA | Even if delta deployments are activated, a deployment in mode **full** will be performed for this Pull Request |\n| PURGE_FLOW_VERSIONS | After deployment, inactive and obsolete Flow Versions will be deleted (equivalent to command sf hardis:org:purge:flow)<br/>**Caution: This will also purge active Flow Interviews !** |\n| DESTRUCTIVE_CHANGES_AFTER_DEPLOYMENT | If a file manifest/destructiveChanges.xml is found, it will be executed in a separate step, after the deployment of the main package |\n\nYou can also override some `.sfdx-hardis.yml` properties directly in the Pull Request description using YAML blocks. Supported keys: `deploymentApexTestClasses`, `commandsPreDeploy`, `commandsPostDeploy`.\n\nExample (in PR description):\n\n```yaml\ndeploymentApexTestClasses:\n - MyTestClass1\n - MyTestClass2\n```\n\n> For example, define `PURGE_FLOW_VERSIONS` and `DESTRUCTIVE_CHANGES_AFTER_DEPLOYMENT` in your Pull Request comments if you want to delete fields that are used in an active flow.\n\nNote: it is also possible to define these behaviors as ENV variables:\n\n- For all deployments (example: `PURGE_FLOW_VERSIONS=true`)\n- For a specific branch, by appending the target branch name (example: `PURGE_FLOW_VERSIONS_UAT=true`)\n\n### Deployment plan (deprecated)\n\n> **This feature is deactivated by default (enable with `enableDeprecatedDeploymentPlan` in project configuration). Use preCommands and postCommands instead.** \n\nIf you need to deploy in multiple steps, you can define a property `deploymentPlan` in `.sfdx-hardis.yml`.\n\n- If a file `manifest/package.xml` is found, it will be placed with order 0 in the deployment plan\n\n- If a file `manifest/destructiveChanges.xml` is found, it will be executed as --postdestructivechanges\n\n- If env var `SFDX_HARDIS_DEPLOY_IGNORE_SPLIT_PACKAGES` is defined as `false` , split of package.xml will be applied\n\nExample:\n\n```yaml\ndeploymentPlan:\n packages:\n - label: Deploy Flow-Workflow\n packageXmlFile: manifest/splits/packageXmlFlowWorkflow.xml\n order: 6\n - label: Deploy SharingRules - Case\n packageXmlFile: manifest/splits/packageXmlSharingRulesCase.xml\n order: 30\n waitAfter: 30\n```\n\n### Automated fixes post deployments\n\n#### List view with scope Mine\n\nIf you defined a property **listViewsToSetToMine** in your .sfdx-hardis.yml, related ListViews will be set to Mine ( see command <https://sfdx-hardis.cloudity.com/hardis/org/fix/listviewmine/> )\n\nExample:\n\n```yaml\nlistViewsToSetToMine:\n - \"Operation__c:MyCurrentOperations\"\n - \"Operation__c:MyFinalizedOperations\"\n - \"Opportunity:Default_Opportunity_Pipeline\"\n - \"Opportunity:MyCurrentSubscriptions\"\n - \"Opportunity:MySubscriptions\"\n - \"Account:MyActivePartners\"\n```\n\nTroubleshooting: if you need to fix ListViews with mine from an alpine-linux based docker image, use this workaround in your dockerfile:\n\n```dockerfile\n# Do not use puppeteer embedded chromium\nRUN apk add --update --no-cache chromium\nENV PUPPETEER_SKIP_CHROMIUM_DOWNLOAD=\"true\"\nENV CHROMIUM_PATH=\"/usr/bin/chromium-browser\"\nENV PUPPETEER_EXECUTABLE_PATH=\"$\\{CHROMIUM_PATH}\" // remove \\ before {\n```\n\nIf you need to increase the deployment waiting time (sf project deploy start --wait arg), you can define env variable SFDX_DEPLOY_WAIT_MINUTES (default: 120)\n\nIf you need notifications to be sent using the current Pull Request and not the one just merged ([see use case](https://github.com/hardisgroupcom/sfdx-hardis/issues/637#issuecomment-2230798904)), define env variable SFDX_HARDIS_DEPLOY_BEFORE_MERGE=true\n\nIf you want to disable the calculation and display of Flow Visual Git Diff in Pull Request comments, define variable **SFDX_DISABLE_FLOW_DIFF=true**\n",
12546
12761
  "examples": [
12547
12762
  "$ sf hardis:project:deploy:smart",
12548
12763
  "$ sf hardis:project:deploy:smart --check",
@@ -13316,221 +13531,6 @@
13316
13531
  "validate:deploy:project:hardis"
13317
13532
  ]
13318
13533
  },
13319
- "hardis:project:fix:profiletabs": {
13320
- "aliases": [],
13321
- "args": {},
13322
- "description": "\n## Command Behavior\n\n**Interactively updates tab visibility settings in Salesforce profiles, addressing a common issue where tab visibilities are not correctly retrieved by `sf project retrieve start`.**\n\nThis command provides a user-friendly interface to manage tab settings within your profile XML files, ensuring that your local project accurately reflects the intended tab configurations in your Salesforce org.\n\nKey functionalities:\n\n- **Interactive Tab Selection:** Displays a multi-select menu of all available tabs in your org, allowing you to choose which tabs to update.\n- **Visibility Control:** Lets you set the visibility for the selected tabs to either `DefaultOn` (Visible) or `Hidden`.\n- **Profile Selection:** Presents a multi-select menu of all .profile-meta.xml files in your project, allowing you to apply the tab visibility changes to specific profiles.\n- **XML Updates:** Modifies the <tabVisibilities> section of the selected profile XML files to reflect the chosen tab settings. If a tab visibility setting already exists for a selected tab, it will be updated; otherwise, a new one will be added.\n- **Sorted Output:** The <tabVisibilities> in the updated profile XML files are sorted alphabetically for consistency and readability.\n\n<details markdown=\"1\">\n<summary>Technical explanations</summary>\n\nThe command's technical implementation involves:\n\n- **SOQL Queries (Tooling API):** It queries the `TabDefinition` object using `soqlQueryTooling` to retrieve a list of all available tabs in the target org.\n- **File Discovery:** Uses `glob` to find all .profile-meta.xml files within the specified project path.\n- **Interactive Prompts:** Leverages the `prompts` library to create interactive menus for selecting tabs, visibility settings, and profiles.\n- **XML Parsing and Manipulation:** Uses `parseXmlFile` to read the content of profile XML files and `writeXmlFile` to write the modified content back. It manipulates the `tabVisibilities` array within the parsed XML to add or update tab settings.\n- **Array Sorting:** Employs the `sort-array` library to sort the `tabVisibilities` alphabetically by tab name.\n- **Logging:** Provides feedback to the user about which profiles have been updated and a summary of the changes.\n</details>\n",
13323
- "examples": [
13324
- "$ sf hardis:project:fix:profiletabs"
13325
- ],
13326
- "flags": {
13327
- "json": {
13328
- "description": "Format output as json.",
13329
- "helpGroup": "GLOBAL",
13330
- "name": "json",
13331
- "allowNo": false,
13332
- "type": "boolean"
13333
- },
13334
- "flags-dir": {
13335
- "helpGroup": "GLOBAL",
13336
- "name": "flags-dir",
13337
- "summary": "Import flag values from a directory.",
13338
- "hasDynamicHelp": false,
13339
- "multiple": false,
13340
- "type": "option"
13341
- },
13342
- "path": {
13343
- "char": "p",
13344
- "description": "Root folder",
13345
- "name": "path",
13346
- "default": "/home/runner/work/sfdx-hardis/sfdx-hardis",
13347
- "hasDynamicHelp": false,
13348
- "multiple": false,
13349
- "type": "option"
13350
- },
13351
- "debug": {
13352
- "char": "d",
13353
- "description": "Activate debug mode (more logs)",
13354
- "name": "debug",
13355
- "allowNo": false,
13356
- "type": "boolean"
13357
- },
13358
- "websocket": {
13359
- "description": "Websocket host:port for VsCode SFDX Hardis UI integration",
13360
- "name": "websocket",
13361
- "hasDynamicHelp": false,
13362
- "multiple": false,
13363
- "type": "option"
13364
- },
13365
- "skipauth": {
13366
- "description": "Skip authentication check when a default username is required",
13367
- "name": "skipauth",
13368
- "allowNo": false,
13369
- "type": "boolean"
13370
- },
13371
- "target-org": {
13372
- "aliases": [
13373
- "targetusername",
13374
- "u"
13375
- ],
13376
- "char": "o",
13377
- "deprecateAliases": true,
13378
- "name": "target-org",
13379
- "noCacheDefault": true,
13380
- "required": true,
13381
- "summary": "Username or alias of the target org. Not required if the `target-org` configuration variable is already set.",
13382
- "hasDynamicHelp": true,
13383
- "multiple": false,
13384
- "type": "option"
13385
- }
13386
- },
13387
- "hasDynamicHelp": true,
13388
- "hiddenAliases": [],
13389
- "id": "hardis:project:fix:profiletabs",
13390
- "pluginAlias": "sfdx-hardis",
13391
- "pluginName": "sfdx-hardis",
13392
- "pluginType": "core",
13393
- "strict": true,
13394
- "enableJsonFlag": true,
13395
- "title": "Fix profiles to add tabs that are not retrieved by SF CLI",
13396
- "requiresProject": true,
13397
- "isESM": true,
13398
- "relativePath": [
13399
- "lib",
13400
- "commands",
13401
- "hardis",
13402
- "project",
13403
- "fix",
13404
- "profiletabs.js"
13405
- ],
13406
- "aliasPermutations": [],
13407
- "permutations": [
13408
- "hardis:project:fix:profiletabs",
13409
- "project:hardis:fix:profiletabs",
13410
- "project:fix:hardis:profiletabs",
13411
- "project:fix:profiletabs:hardis",
13412
- "hardis:fix:project:profiletabs",
13413
- "fix:hardis:project:profiletabs",
13414
- "fix:project:hardis:profiletabs",
13415
- "fix:project:profiletabs:hardis",
13416
- "hardis:fix:profiletabs:project",
13417
- "fix:hardis:profiletabs:project",
13418
- "fix:profiletabs:hardis:project",
13419
- "fix:profiletabs:project:hardis",
13420
- "hardis:project:profiletabs:fix",
13421
- "project:hardis:profiletabs:fix",
13422
- "project:profiletabs:hardis:fix",
13423
- "project:profiletabs:fix:hardis",
13424
- "hardis:profiletabs:project:fix",
13425
- "profiletabs:hardis:project:fix",
13426
- "profiletabs:project:hardis:fix",
13427
- "profiletabs:project:fix:hardis",
13428
- "hardis:profiletabs:fix:project",
13429
- "profiletabs:hardis:fix:project",
13430
- "profiletabs:fix:hardis:project",
13431
- "profiletabs:fix:project:hardis"
13432
- ]
13433
- },
13434
- "hardis:project:fix:v53flexipages": {
13435
- "aliases": [],
13436
- "args": {},
13437
- "description": "\n## Command Behavior\n\n**Fixes Salesforce FlexiPages for compatibility with API Version 53.0 (Winter '22 release) by adding missing identifiers to component instances.**\n\nSalesforce introduced a change in API Version 53.0 that requires `identifier` tags within `componentInstance` and `fieldInstance` elements in FlexiPage metadata. If these identifiers are missing, deployments to orgs with API version 53.0 or higher will fail. This command automates the process of adding these missing identifiers, ensuring your FlexiPages remain deployable.\n\nKey functionalities:\n\n- **Targeted FlexiPage Processing:** Scans all .flexipage-meta.xml files within the specified root folder (defaults to current working directory).\n- **Identifier Injection:** Inserts a unique `identifier` tag (e.g., `SFDX_HARDIS_REPLACEMENT_ID`) into `componentInstance` and `fieldInstance` elements that lack one.\n\n**Important Note:** After running this command, ensure you update your `apiVersion` to `53.0` (or higher) in your `package.xml` and `sfdx-project.json` files.\n\n<details markdown=\"1\">\n<summary>Technical explanations</summary>\n\nThe command's technical implementation involves:\n\n- **File Discovery:** Uses `glob` to find all .flexipage-meta.xml files.\n- **Content Reading:** Reads the XML content of each FlexiPage file.\n- **Regular Expression Replacement:** Employs a set of regular expressions to identify specific XML patterns (componentName.../componentName.../componentInstance, componentName.../componentName.../visibilityRule, fieldItem.../fieldItem.../fieldInstance) that are missing the `identifier` tag.\n- **Dynamic ID Generation:** For each match, it generates a unique identifier (e.g., `sfdxHardisIdX`) and injects it into the XML structure.\n- **File Writing:** If changes are made, the modified XML content is written back to the FlexiPage file using `fs.writeFile`.\n- **Logging:** Provides messages about which FlexiPages are being processed and a summary of the total number of identifiers added.\n</details>\n",
13438
- "examples": [
13439
- "$ sf hardis:project:fix:v53flexipages"
13440
- ],
13441
- "flags": {
13442
- "json": {
13443
- "description": "Format output as json.",
13444
- "helpGroup": "GLOBAL",
13445
- "name": "json",
13446
- "allowNo": false,
13447
- "type": "boolean"
13448
- },
13449
- "flags-dir": {
13450
- "helpGroup": "GLOBAL",
13451
- "name": "flags-dir",
13452
- "summary": "Import flag values from a directory.",
13453
- "hasDynamicHelp": false,
13454
- "multiple": false,
13455
- "type": "option"
13456
- },
13457
- "path": {
13458
- "char": "p",
13459
- "description": "Root folder",
13460
- "name": "path",
13461
- "default": "/home/runner/work/sfdx-hardis/sfdx-hardis",
13462
- "hasDynamicHelp": false,
13463
- "multiple": false,
13464
- "type": "option"
13465
- },
13466
- "debug": {
13467
- "char": "d",
13468
- "description": "Activate debug mode (more logs)",
13469
- "name": "debug",
13470
- "allowNo": false,
13471
- "type": "boolean"
13472
- },
13473
- "websocket": {
13474
- "description": "Websocket host:port for VsCode SFDX Hardis UI integration",
13475
- "name": "websocket",
13476
- "hasDynamicHelp": false,
13477
- "multiple": false,
13478
- "type": "option"
13479
- },
13480
- "skipauth": {
13481
- "description": "Skip authentication check when a default username is required",
13482
- "name": "skipauth",
13483
- "allowNo": false,
13484
- "type": "boolean"
13485
- }
13486
- },
13487
- "hasDynamicHelp": false,
13488
- "hiddenAliases": [],
13489
- "id": "hardis:project:fix:v53flexipages",
13490
- "pluginAlias": "sfdx-hardis",
13491
- "pluginName": "sfdx-hardis",
13492
- "pluginType": "core",
13493
- "strict": true,
13494
- "enableJsonFlag": true,
13495
- "title": "Fix flexipages for v53",
13496
- "requiresProject": true,
13497
- "isESM": true,
13498
- "relativePath": [
13499
- "lib",
13500
- "commands",
13501
- "hardis",
13502
- "project",
13503
- "fix",
13504
- "v53flexipages.js"
13505
- ],
13506
- "aliasPermutations": [],
13507
- "permutations": [
13508
- "hardis:project:fix:v53flexipages",
13509
- "project:hardis:fix:v53flexipages",
13510
- "project:fix:hardis:v53flexipages",
13511
- "project:fix:v53flexipages:hardis",
13512
- "hardis:fix:project:v53flexipages",
13513
- "fix:hardis:project:v53flexipages",
13514
- "fix:project:hardis:v53flexipages",
13515
- "fix:project:v53flexipages:hardis",
13516
- "hardis:fix:v53flexipages:project",
13517
- "fix:hardis:v53flexipages:project",
13518
- "fix:v53flexipages:hardis:project",
13519
- "fix:v53flexipages:project:hardis",
13520
- "hardis:project:v53flexipages:fix",
13521
- "project:hardis:v53flexipages:fix",
13522
- "project:v53flexipages:hardis:fix",
13523
- "project:v53flexipages:fix:hardis",
13524
- "hardis:v53flexipages:project:fix",
13525
- "v53flexipages:hardis:project:fix",
13526
- "v53flexipages:project:hardis:fix",
13527
- "v53flexipages:project:fix:hardis",
13528
- "hardis:v53flexipages:fix:project",
13529
- "v53flexipages:hardis:fix:project",
13530
- "v53flexipages:fix:hardis:project",
13531
- "v53flexipages:fix:project:hardis"
13532
- ]
13533
- },
13534
13534
  "hardis:project:generate:bypass": {
13535
13535
  "aliases": [],
13536
13536
  "args": {},
@@ -16104,5 +16104,5 @@
16104
16104
  ]
16105
16105
  }
16106
16106
  },
16107
- "version": "6.17.1"
16107
+ "version": "6.17.2-alpha202512261505.0"
16108
16108
  }