sfdx-hardis 6.0.4-beta202508121754.0 → 6.0.4-beta202508131002.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.
@@ -132,13 +132,12 @@
132
132
  "clear:cache:hardis"
133
133
  ]
134
134
  },
135
- "hardis:auth:login": {
135
+ "hardis:config:get": {
136
136
  "aliases": [],
137
137
  "args": {},
138
- "description": "\n## Command Behavior\n\n**Authenticates to a Salesforce org, primarily designed for CI/CD workflows.**\n\nThis command facilitates secure and automated logins to Salesforce organizations within continuous integration and continuous delivery pipelines. It leverages pre-configured authentication details, ensuring that CI/CD processes can interact with Salesforce without manual intervention.\n\nKey aspects:\n\n- **Configuration-Driven:** It relies on authentication variables and files set up by dedicated configuration commands:\n - For CI/CD repositories: [Configure Org CI Authentication](https://sfdx-hardis.cloudity.com/hardis/project/configure/auth/)\n - For Monitoring repositories: [Configure Org Monitoring](https://sfdx-hardis.cloudity.com/hardis/org/configure/monitoring/)\n- **Technical Org Support:** Supports authentication to a 'technical org' (e.g., for calling Agentforce from another org) by utilizing the `SFDX_AUTH_URL_TECHNICAL_ORG` environment variable. If this variable is set, the command authenticates to this org with the alias `TECHNICAL_ORG`.\n\nTo obtain the `SFDX_AUTH_URL_TECHNICAL_ORG` value, you can run `sf org display --verbose --json` and copy the `sfdxAuthUrl` field from the output.\n\n## Technical explanations\n\nThe command's technical flow involves:\n\n- **Flag Parsing:** It parses command-line flags such as `instanceurl`, `devhub`, `scratchorg`, and `debug` to determine the authentication context.\n- **Authentication Hook:** It triggers an internal authentication hook (`this.config.runHook('auth', ...`)) which is responsible for executing the actual authentication logic based on the provided flags (e.g., whether it's a Dev Hub or a scratch org).\n- **Environment Variable Check:** It checks for the presence of `SFDX_AUTH_URL_TECHNICAL_ORG` or `TECHNICAL_ORG_ALIAS` environment variables.\n- **`authOrg` Utility:** If a technical org is configured, it calls the `authOrg` utility function to perform the authentication for that specific org, ensuring it's connected and available for subsequent operations.\n- **Salesforce CLI Integration:** It integrates with the Salesforce CLI's authentication mechanisms to establish and manage org connections.\n",
138
+ "description": "\n## Command Behavior\n\n**Retrieves and displays the sfdx-hardis configuration for a specified level.**\n\nThis command allows you to inspect the configuration that is currently in effect for your project, which is useful for debugging and understanding how sfdx-hardis will behave.\n\n- **Configuration levels:** It can retrieve configuration from three different levels:\n - **Project:** The configuration defined in the project's `.sfdx-hardis.yml` file.\n - **Branch:** The configuration defined in a branch-specific configuration file (e.g., `.sfdx-hardis.production.yml`).\n - **User:** The global user-level configuration.\n\n## Technical explanations\n\nThe command's logic is straightforward:\n\n- **`getConfig` function:** It calls the `getConfig` utility function, passing the desired configuration level as an argument.\n- **Configuration loading:** The `getConfig` function is responsible for finding the appropriate configuration file, reading its contents, and parsing it as YAML or JSON.\n- **Output:** The retrieved configuration is then displayed to the user as a JSON string.\n",
139
139
  "examples": [
140
- "$ sf hardis:auth:login",
141
- "CI=true sf hardis:auth:login"
140
+ "$ sf hardis:project:deploy:sources:metadata"
142
141
  ],
143
142
  "flags": {
144
143
  "json": {
@@ -156,28 +155,20 @@
156
155
  "multiple": false,
157
156
  "type": "option"
158
157
  },
159
- "instanceurl": {
160
- "char": "r",
161
- "description": "URL of org instance",
162
- "name": "instanceurl",
158
+ "level": {
159
+ "char": "l",
160
+ "description": "project,branch or user",
161
+ "name": "level",
162
+ "default": "project",
163
163
  "hasDynamicHelp": false,
164
164
  "multiple": false,
165
+ "options": [
166
+ "project",
167
+ "branch",
168
+ "user"
169
+ ],
165
170
  "type": "option"
166
171
  },
167
- "devhub": {
168
- "char": "h",
169
- "description": "Also connect associated DevHub",
170
- "name": "devhub",
171
- "allowNo": false,
172
- "type": "boolean"
173
- },
174
- "scratchorg": {
175
- "char": "s",
176
- "description": "Scratch org",
177
- "name": "scratchorg",
178
- "allowNo": false,
179
- "type": "boolean"
180
- },
181
172
  "debug": {
182
173
  "char": "d",
183
174
  "description": "Activate debug mode (more logs)",
@@ -201,38 +192,39 @@
201
192
  },
202
193
  "hasDynamicHelp": false,
203
194
  "hiddenAliases": [],
204
- "id": "hardis:auth:login",
195
+ "id": "hardis:config:get",
205
196
  "pluginAlias": "sfdx-hardis",
206
197
  "pluginName": "sfdx-hardis",
207
198
  "pluginType": "core",
208
199
  "strict": true,
209
200
  "enableJsonFlag": true,
210
- "title": "Login",
201
+ "title": "Deploy metadata sources to org",
211
202
  "requiresProject": false,
212
203
  "isESM": true,
213
204
  "relativePath": [
214
205
  "lib",
215
206
  "commands",
216
207
  "hardis",
217
- "auth",
218
- "login.js"
208
+ "config",
209
+ "get.js"
219
210
  ],
220
211
  "aliasPermutations": [],
221
212
  "permutations": [
222
- "hardis:auth:login",
223
- "auth:hardis:login",
224
- "auth:login:hardis",
225
- "hardis:login:auth",
226
- "login:hardis:auth",
227
- "login:auth:hardis"
213
+ "hardis:config:get",
214
+ "config:hardis:get",
215
+ "config:get:hardis",
216
+ "hardis:get:config",
217
+ "get:hardis:config",
218
+ "get:config:hardis"
228
219
  ]
229
220
  },
230
- "hardis:config:get": {
221
+ "hardis:auth:login": {
231
222
  "aliases": [],
232
223
  "args": {},
233
- "description": "\n## Command Behavior\n\n**Retrieves and displays the sfdx-hardis configuration for a specified level.**\n\nThis command allows you to inspect the configuration that is currently in effect for your project, which is useful for debugging and understanding how sfdx-hardis will behave.\n\n- **Configuration levels:** It can retrieve configuration from three different levels:\n - **Project:** The configuration defined in the project's `.sfdx-hardis.yml` file.\n - **Branch:** The configuration defined in a branch-specific configuration file (e.g., `.sfdx-hardis.production.yml`).\n - **User:** The global user-level configuration.\n\n## Technical explanations\n\nThe command's logic is straightforward:\n\n- **`getConfig` function:** It calls the `getConfig` utility function, passing the desired configuration level as an argument.\n- **Configuration loading:** The `getConfig` function is responsible for finding the appropriate configuration file, reading its contents, and parsing it as YAML or JSON.\n- **Output:** The retrieved configuration is then displayed to the user as a JSON string.\n",
224
+ "description": "\n## Command Behavior\n\n**Authenticates to a Salesforce org, primarily designed for CI/CD workflows.**\n\nThis command facilitates secure and automated logins to Salesforce organizations within continuous integration and continuous delivery pipelines. It leverages pre-configured authentication details, ensuring that CI/CD processes can interact with Salesforce without manual intervention.\n\nKey aspects:\n\n- **Configuration-Driven:** It relies on authentication variables and files set up by dedicated configuration commands:\n - For CI/CD repositories: [Configure Org CI Authentication](https://sfdx-hardis.cloudity.com/hardis/project/configure/auth/)\n - For Monitoring repositories: [Configure Org Monitoring](https://sfdx-hardis.cloudity.com/hardis/org/configure/monitoring/)\n- **Technical Org Support:** Supports authentication to a 'technical org' (e.g., for calling Agentforce from another org) by utilizing the `SFDX_AUTH_URL_TECHNICAL_ORG` environment variable. If this variable is set, the command authenticates to this org with the alias `TECHNICAL_ORG`.\n\nTo obtain the `SFDX_AUTH_URL_TECHNICAL_ORG` value, you can run `sf org display --verbose --json` and copy the `sfdxAuthUrl` field from the output.\n\n## Technical explanations\n\nThe command's technical flow involves:\n\n- **Flag Parsing:** It parses command-line flags such as `instanceurl`, `devhub`, `scratchorg`, and `debug` to determine the authentication context.\n- **Authentication Hook:** It triggers an internal authentication hook (`this.config.runHook('auth', ...`)) which is responsible for executing the actual authentication logic based on the provided flags (e.g., whether it's a Dev Hub or a scratch org).\n- **Environment Variable Check:** It checks for the presence of `SFDX_AUTH_URL_TECHNICAL_ORG` or `TECHNICAL_ORG_ALIAS` environment variables.\n- **`authOrg` Utility:** If a technical org is configured, it calls the `authOrg` utility function to perform the authentication for that specific org, ensuring it's connected and available for subsequent operations.\n- **Salesforce CLI Integration:** It integrates with the Salesforce CLI's authentication mechanisms to establish and manage org connections.\n",
234
225
  "examples": [
235
- "$ sf hardis:project:deploy:sources:metadata"
226
+ "$ sf hardis:auth:login",
227
+ "CI=true sf hardis:auth:login"
236
228
  ],
237
229
  "flags": {
238
230
  "json": {
@@ -250,20 +242,28 @@
250
242
  "multiple": false,
251
243
  "type": "option"
252
244
  },
253
- "level": {
254
- "char": "l",
255
- "description": "project,branch or user",
256
- "name": "level",
257
- "default": "project",
245
+ "instanceurl": {
246
+ "char": "r",
247
+ "description": "URL of org instance",
248
+ "name": "instanceurl",
258
249
  "hasDynamicHelp": false,
259
250
  "multiple": false,
260
- "options": [
261
- "project",
262
- "branch",
263
- "user"
264
- ],
265
251
  "type": "option"
266
252
  },
253
+ "devhub": {
254
+ "char": "h",
255
+ "description": "Also connect associated DevHub",
256
+ "name": "devhub",
257
+ "allowNo": false,
258
+ "type": "boolean"
259
+ },
260
+ "scratchorg": {
261
+ "char": "s",
262
+ "description": "Scratch org",
263
+ "name": "scratchorg",
264
+ "allowNo": false,
265
+ "type": "boolean"
266
+ },
267
267
  "debug": {
268
268
  "char": "d",
269
269
  "description": "Activate debug mode (more logs)",
@@ -287,30 +287,30 @@
287
287
  },
288
288
  "hasDynamicHelp": false,
289
289
  "hiddenAliases": [],
290
- "id": "hardis:config:get",
290
+ "id": "hardis:auth:login",
291
291
  "pluginAlias": "sfdx-hardis",
292
292
  "pluginName": "sfdx-hardis",
293
293
  "pluginType": "core",
294
294
  "strict": true,
295
295
  "enableJsonFlag": true,
296
- "title": "Deploy metadata sources to org",
296
+ "title": "Login",
297
297
  "requiresProject": false,
298
298
  "isESM": true,
299
299
  "relativePath": [
300
300
  "lib",
301
301
  "commands",
302
302
  "hardis",
303
- "config",
304
- "get.js"
303
+ "auth",
304
+ "login.js"
305
305
  ],
306
306
  "aliasPermutations": [],
307
307
  "permutations": [
308
- "hardis:config:get",
309
- "config:hardis:get",
310
- "config:get:hardis",
311
- "hardis:get:config",
312
- "get:hardis:config",
313
- "get:config:hardis"
308
+ "hardis:auth:login",
309
+ "auth:hardis:login",
310
+ "auth:login:hardis",
311
+ "hardis:login:auth",
312
+ "login:hardis:auth",
313
+ "login:auth:hardis"
314
314
  ]
315
315
  },
316
316
  "hardis:doc:fieldusage": {
@@ -867,7 +867,8 @@
867
867
  "examples": [
868
868
  "$ sf hardis:doc:project2markdown",
869
869
  "$ sf hardis:doc:project2markdown --with-history",
870
- "$ sf hardis:doc:project2markdown --with-history --pdf"
870
+ "$ sf hardis:doc:project2markdown --with-history --pdf",
871
+ "$ sf hardis:doc:project2markdown --hide-apex-code"
871
872
  ],
872
873
  "flags": {
873
874
  "json": {
@@ -903,6 +904,12 @@
903
904
  "allowNo": false,
904
905
  "type": "boolean"
905
906
  },
907
+ "hide-apex-code": {
908
+ "description": "Hide Apex code in the generated documentation for Apex classes.",
909
+ "name": "hide-apex-code",
910
+ "allowNo": false,
911
+ "type": "boolean"
912
+ },
906
913
  "debug": {
907
914
  "char": "d",
908
915
  "description": "Activate debug mode (more logs)",
@@ -5859,6 +5866,128 @@
5859
5866
  "listviewmine:fix:org:hardis"
5860
5867
  ]
5861
5868
  },
5869
+ "hardis:org:generate:packagexmlfull": {
5870
+ "aliases": [],
5871
+ "args": {},
5872
+ "description": "\n## Command Behavior\n\n**Generates a comprehensive `package.xml` file for a Salesforce org, including all metadata components, even managed ones.**\n\nThis command is essential for various Salesforce development and administration tasks, especially when you need a complete snapshot of an org's metadata. It goes beyond typical source tracking by including managed package components, which is crucial for understanding the full metadata footprint of an org.\n\nKey functionalities:\n\n- **Full Org Metadata Retrieval:** Connects to a specified Salesforce org (or prompts for one if not provided) and retrieves a complete list of all metadata types and their members.\n- **Managed Package Inclusion:** Unlike standard source retrieval, this command explicitly includes metadata from managed packages, providing a truly comprehensive `package.xml`.\n- **Customizable Output:** Allows you to specify the output file path for the generated `package.xml`.\n- **Interactive Org Selection:** If no target org is specified, it interactively prompts the user to choose an org. (or use --no-prompt to skip this step)\n\n## Technical explanations\n\nThe command's technical implementation involves:\n\n- **Salesforce Metadata API Interaction:** It leverages the Salesforce Metadata API to list all available metadata types and then retrieve all components for each type.\n- **`buildOrgManifest` Utility:** The core logic for querying the org's metadata and constructing the `package.xml` is encapsulated within the `buildOrgManifest` utility function.\n- **XML Generation:** It dynamically builds the XML structure of the `package.xml` file, including the `types` and `members` elements for all retrieved metadata.\n- **File System Operations:** It writes the generated `package.xml` file to the specified output path.\n- **Interactive Prompts:** Uses `promptOrgUsernameDefault` to guide the user in selecting the target Salesforce org.\n",
5873
+ "examples": [
5874
+ "$ sf hardis:org:generate:packagexmlfull",
5875
+ "$ sf hardis:org:generate:packagexmlfull --outputfile /tmp/packagexmlfull.xml",
5876
+ "$ sf hardis:org:generate:packagexmlfull --target-org nico@example.com"
5877
+ ],
5878
+ "flags": {
5879
+ "json": {
5880
+ "description": "Format output as json.",
5881
+ "helpGroup": "GLOBAL",
5882
+ "name": "json",
5883
+ "allowNo": false,
5884
+ "type": "boolean"
5885
+ },
5886
+ "flags-dir": {
5887
+ "helpGroup": "GLOBAL",
5888
+ "name": "flags-dir",
5889
+ "summary": "Import flag values from a directory.",
5890
+ "hasDynamicHelp": false,
5891
+ "multiple": false,
5892
+ "type": "option"
5893
+ },
5894
+ "outputfile": {
5895
+ "description": "Output package.xml file",
5896
+ "name": "outputfile",
5897
+ "hasDynamicHelp": false,
5898
+ "multiple": false,
5899
+ "type": "option"
5900
+ },
5901
+ "debug": {
5902
+ "char": "d",
5903
+ "description": "Activate debug mode (more logs)",
5904
+ "name": "debug",
5905
+ "allowNo": false,
5906
+ "type": "boolean"
5907
+ },
5908
+ "no-prompt": {
5909
+ "char": "n",
5910
+ "description": "Do not prompt for org username, use the default one",
5911
+ "name": "no-prompt",
5912
+ "allowNo": false,
5913
+ "type": "boolean"
5914
+ },
5915
+ "websocket": {
5916
+ "description": "Websocket host:port for VsCode SFDX Hardis UI integration",
5917
+ "name": "websocket",
5918
+ "hasDynamicHelp": false,
5919
+ "multiple": false,
5920
+ "type": "option"
5921
+ },
5922
+ "skipauth": {
5923
+ "description": "Skip authentication check when a default username is required",
5924
+ "name": "skipauth",
5925
+ "allowNo": false,
5926
+ "type": "boolean"
5927
+ },
5928
+ "target-org": {
5929
+ "aliases": [
5930
+ "targetusername",
5931
+ "u"
5932
+ ],
5933
+ "char": "o",
5934
+ "deprecateAliases": true,
5935
+ "name": "target-org",
5936
+ "noCacheDefault": true,
5937
+ "required": true,
5938
+ "summary": "Username or alias of the target org. Not required if the `target-org` configuration variable is already set.",
5939
+ "hasDynamicHelp": true,
5940
+ "multiple": false,
5941
+ "type": "option"
5942
+ }
5943
+ },
5944
+ "hasDynamicHelp": true,
5945
+ "hiddenAliases": [],
5946
+ "id": "hardis:org:generate:packagexmlfull",
5947
+ "pluginAlias": "sfdx-hardis",
5948
+ "pluginName": "sfdx-hardis",
5949
+ "pluginType": "core",
5950
+ "strict": true,
5951
+ "enableJsonFlag": true,
5952
+ "title": "Generate Full Org package.xml",
5953
+ "requiresProject": false,
5954
+ "isESM": true,
5955
+ "relativePath": [
5956
+ "lib",
5957
+ "commands",
5958
+ "hardis",
5959
+ "org",
5960
+ "generate",
5961
+ "packagexmlfull.js"
5962
+ ],
5963
+ "aliasPermutations": [],
5964
+ "permutations": [
5965
+ "hardis:org:generate:packagexmlfull",
5966
+ "org:hardis:generate:packagexmlfull",
5967
+ "org:generate:hardis:packagexmlfull",
5968
+ "org:generate:packagexmlfull:hardis",
5969
+ "hardis:generate:org:packagexmlfull",
5970
+ "generate:hardis:org:packagexmlfull",
5971
+ "generate:org:hardis:packagexmlfull",
5972
+ "generate:org:packagexmlfull:hardis",
5973
+ "hardis:generate:packagexmlfull:org",
5974
+ "generate:hardis:packagexmlfull:org",
5975
+ "generate:packagexmlfull:hardis:org",
5976
+ "generate:packagexmlfull:org:hardis",
5977
+ "hardis:org:packagexmlfull:generate",
5978
+ "org:hardis:packagexmlfull:generate",
5979
+ "org:packagexmlfull:hardis:generate",
5980
+ "org:packagexmlfull:generate:hardis",
5981
+ "hardis:packagexmlfull:org:generate",
5982
+ "packagexmlfull:hardis:org:generate",
5983
+ "packagexmlfull:org:hardis:generate",
5984
+ "packagexmlfull:org:generate:hardis",
5985
+ "hardis:packagexmlfull:generate:org",
5986
+ "packagexmlfull:hardis:generate:org",
5987
+ "packagexmlfull:generate:hardis:org",
5988
+ "packagexmlfull:generate:org:hardis"
5989
+ ]
5990
+ },
5862
5991
  "hardis:org:diagnose:audittrail": {
5863
5992
  "aliases": [],
5864
5993
  "args": {},
@@ -7008,134 +7137,12 @@
7008
7137
  "unusedusers:diagnose:org:hardis"
7009
7138
  ]
7010
7139
  },
7011
- "hardis:org:generate:packagexmlfull": {
7140
+ "hardis:org:monitor:all": {
7012
7141
  "aliases": [],
7013
7142
  "args": {},
7014
- "description": "\n## Command Behavior\n\n**Generates a comprehensive `package.xml` file for a Salesforce org, including all metadata components, even managed ones.**\n\nThis command is essential for various Salesforce development and administration tasks, especially when you need a complete snapshot of an org's metadata. It goes beyond typical source tracking by including managed package components, which is crucial for understanding the full metadata footprint of an org.\n\nKey functionalities:\n\n- **Full Org Metadata Retrieval:** Connects to a specified Salesforce org (or prompts for one if not provided) and retrieves a complete list of all metadata types and their members.\n- **Managed Package Inclusion:** Unlike standard source retrieval, this command explicitly includes metadata from managed packages, providing a truly comprehensive `package.xml`.\n- **Customizable Output:** Allows you to specify the output file path for the generated `package.xml`.\n- **Interactive Org Selection:** If no target org is specified, it interactively prompts the user to choose an org. (or use --no-prompt to skip this step)\n\n## Technical explanations\n\nThe command's technical implementation involves:\n\n- **Salesforce Metadata API Interaction:** It leverages the Salesforce Metadata API to list all available metadata types and then retrieve all components for each type.\n- **`buildOrgManifest` Utility:** The core logic for querying the org's metadata and constructing the `package.xml` is encapsulated within the `buildOrgManifest` utility function.\n- **XML Generation:** It dynamically builds the XML structure of the `package.xml` file, including the `types` and `members` elements for all retrieved metadata.\n- **File System Operations:** It writes the generated `package.xml` file to the specified output path.\n- **Interactive Prompts:** Uses `promptOrgUsernameDefault` to guide the user in selecting the target Salesforce org.\n",
7143
+ "description": "Monitor org, generate reports and sends notifications\n\nYou can disable some commands defining either a **monitoringDisable** property in `.sfdx-hardis.yml`, or a comma separated list in env variable **MONITORING_DISABLE**\n\nExample in .sfdx-hardis.yml:\n \n```yaml\nmonitoringDisable:\n - METADATA_STATUS\n - MISSING_ATTRIBUTES\n - UNUSED_METADATAS\n```\n \nExample in env var:\n\n```sh\nMONITORING_DISABLE=METADATA_STATUS,MISSING_ATTRIBUTES,UNUSED_METADATAS\n```\n\nA [default list of monitoring commands](https://sfdx-hardis.cloudity.com/salesforce-monitoring-home/#monitoring-commands) is used, if you want to override it you can define property **monitoringCommands** in your .sfdx-hardis.yml file\n\nExample:\n\n```yaml\nmonitoringCommands:\n - title: My Custom command\n command: sf my:custom:command\n - title: My Custom command 2\n command: sf my:other:custom:command\n```\n\nYou can force the daily run of all commands by defining env var `MONITORING_IGNORE_FREQUENCY=true`\n\nThe default list of commands is the following:\n\n| Key | Description | Command | Frequency |\n| :---: | :---- | :---- | :-----: |\n| [AUDIT_TRAIL](https://sfdx-hardis.cloudity.com/hardis/org/diagnose/audittrail) | Detect suspect setup actions in major org | [sf hardis:org:diagnose:audittrail](https://sfdx-hardis.cloudity.com/hardis/org/diagnose/audittrail) | daily |\n| [LEGACY_API](https://sfdx-hardis.cloudity.com/hardis/org/diagnose/legacyapi) | Detect calls to deprecated API versions | [sf hardis:org:diagnose:legacyapi](https://sfdx-hardis.cloudity.com/hardis/org/diagnose/legacyapi) | daily |\n| [ORG_LIMITS](https://sfdx-hardis.cloudity.com/hardis/org/monitor/limits) | Detect if org limits are close to be reached | [sf hardis:org:monitor:limits](https://sfdx-hardis.cloudity.com/hardis/org/monitor/limits) | daily |\n| [LICENSES](https://sfdx-hardis.cloudity.com/hardis/org/diagnose/licenses) | Extract licenses information | [sf hardis:org:diagnose:licenses](https://sfdx-hardis.cloudity.com/hardis/org/diagnose/licenses) | weekly |\n| [LINT_ACCESS](https://sfdx-hardis.cloudity.com/hardis/lint/access) | Detect custom elements with no access rights defined in permission sets | [sf hardis:lint:access](https://sfdx-hardis.cloudity.com/hardis/lint/access) | weekly |\n| [UNUSED_LICENSES](https://sfdx-hardis.cloudity.com/hardis/org/diagnose/unusedlicenses) | Detect permission set licenses that are assigned to users that do not need them | [sf hardis:org:diagnose:unusedlicenses](https://sfdx-hardis.cloudity.com/hardis/org/diagnose/unusedlicenses) | weekly |\n| [UNUSED_USERS](https://sfdx-hardis.cloudity.com/hardis/org/diagnose/unusedusers) | Detect active users without recent logins | [sf hardis:org:diagnose:unusedusers](https://sfdx-hardis.cloudity.com/hardis/org/diagnose/unusedusers) | weekly |\n| [ACTIVE_USERS](https://sfdx-hardis.cloudity.com/hardis/org/diagnose/unusedusers) | Detect active users with recent logins | [sf hardis:org:diagnose:unusedusers --returnactiveusers](https://sfdx-hardis.cloudity.com/hardis/org/diagnose/unusedusers) | weekly |\n| [ORG_INFO](https://sfdx-hardis.cloudity.com/hardis/org/diagnose/instanceupgrade) | Get org info + SF instance info + next major upgrade date | [sf hardis:org:diagnose:instanceupgrade](https://sfdx-hardis.cloudity.com/hardis/org/diagnose/instanceupgrade) | weekly |\n| [RELEASE_UPDATES](https://sfdx-hardis.cloudity.com/hardis/org/diagnose/releaseupdates) | Gather warnings about incoming and overdue Release Updates | [sf hardis:org:diagnose:releaseupdates](https://sfdx-hardis.cloudity.com/hardis/org/diagnose/releaseupdates) | weekly |\n| [UNUSED_METADATAS](https://sfdx-hardis.cloudity.com/hardis/lint/unusedmetadatas) | Detect custom labels and custom permissions that are not in use | [sf hardis:lint:unusedmetadatas](https://sfdx-hardis.cloudity.com/hardis/lint/unusedmetadatas) | weekly |\n| [UNUSED_APEX_CLASSES](https://sfdx-hardis.cloudity.com/hardis/org/diagnose/unused-apex-classes) | Detect unused Apex classes in an org | [sf hardis:org:diagnose:unused-apex-classes](https://sfdx-hardis.cloudity.com/hardis/org/diagnose/unused-apex-classes) | weekly |\n| [CONNECTED_APPS](https://sfdx-hardis.cloudity.com/hardis/org/diagnose/unused-connected-apps) | Detect unused Connected Apps in an org | [sf hardis:org:diagnose:unused-connected-apps](https://sfdx-hardis.cloudity.com/hardis/org/diagnose/unused-connected-apps) | weekly |\n| [METADATA_STATUS](https://sfdx-hardis.cloudity.com/hardis/lint/metadatastatus) | Detect inactive metadata | [sf hardis:lint:metadatastatus](https://sfdx-hardis.cloudity.com/hardis/lint/metadatastatus) | weekly |\n| [MISSING_ATTRIBUTES](https://sfdx-hardis.cloudity.com/hardis/lint/missingattributes) | Detect missing description on custom field | [sf hardis:lint:missingattributes](https://sfdx-hardis.cloudity.com/hardis/lint/missingattributes) | weekly |\n\n",
7015
7144
  "examples": [
7016
- "$ sf hardis:org:generate:packagexmlfull",
7017
- "$ sf hardis:org:generate:packagexmlfull --outputfile /tmp/packagexmlfull.xml",
7018
- "$ sf hardis:org:generate:packagexmlfull --target-org nico@example.com"
7019
- ],
7020
- "flags": {
7021
- "json": {
7022
- "description": "Format output as json.",
7023
- "helpGroup": "GLOBAL",
7024
- "name": "json",
7025
- "allowNo": false,
7026
- "type": "boolean"
7027
- },
7028
- "flags-dir": {
7029
- "helpGroup": "GLOBAL",
7030
- "name": "flags-dir",
7031
- "summary": "Import flag values from a directory.",
7032
- "hasDynamicHelp": false,
7033
- "multiple": false,
7034
- "type": "option"
7035
- },
7036
- "outputfile": {
7037
- "description": "Output package.xml file",
7038
- "name": "outputfile",
7039
- "hasDynamicHelp": false,
7040
- "multiple": false,
7041
- "type": "option"
7042
- },
7043
- "debug": {
7044
- "char": "d",
7045
- "description": "Activate debug mode (more logs)",
7046
- "name": "debug",
7047
- "allowNo": false,
7048
- "type": "boolean"
7049
- },
7050
- "no-prompt": {
7051
- "char": "n",
7052
- "description": "Do not prompt for org username, use the default one",
7053
- "name": "no-prompt",
7054
- "allowNo": false,
7055
- "type": "boolean"
7056
- },
7057
- "websocket": {
7058
- "description": "Websocket host:port for VsCode SFDX Hardis UI integration",
7059
- "name": "websocket",
7060
- "hasDynamicHelp": false,
7061
- "multiple": false,
7062
- "type": "option"
7063
- },
7064
- "skipauth": {
7065
- "description": "Skip authentication check when a default username is required",
7066
- "name": "skipauth",
7067
- "allowNo": false,
7068
- "type": "boolean"
7069
- },
7070
- "target-org": {
7071
- "aliases": [
7072
- "targetusername",
7073
- "u"
7074
- ],
7075
- "char": "o",
7076
- "deprecateAliases": true,
7077
- "name": "target-org",
7078
- "noCacheDefault": true,
7079
- "required": true,
7080
- "summary": "Username or alias of the target org. Not required if the `target-org` configuration variable is already set.",
7081
- "hasDynamicHelp": true,
7082
- "multiple": false,
7083
- "type": "option"
7084
- }
7085
- },
7086
- "hasDynamicHelp": true,
7087
- "hiddenAliases": [],
7088
- "id": "hardis:org:generate:packagexmlfull",
7089
- "pluginAlias": "sfdx-hardis",
7090
- "pluginName": "sfdx-hardis",
7091
- "pluginType": "core",
7092
- "strict": true,
7093
- "enableJsonFlag": true,
7094
- "title": "Generate Full Org package.xml",
7095
- "requiresProject": false,
7096
- "isESM": true,
7097
- "relativePath": [
7098
- "lib",
7099
- "commands",
7100
- "hardis",
7101
- "org",
7102
- "generate",
7103
- "packagexmlfull.js"
7104
- ],
7105
- "aliasPermutations": [],
7106
- "permutations": [
7107
- "hardis:org:generate:packagexmlfull",
7108
- "org:hardis:generate:packagexmlfull",
7109
- "org:generate:hardis:packagexmlfull",
7110
- "org:generate:packagexmlfull:hardis",
7111
- "hardis:generate:org:packagexmlfull",
7112
- "generate:hardis:org:packagexmlfull",
7113
- "generate:org:hardis:packagexmlfull",
7114
- "generate:org:packagexmlfull:hardis",
7115
- "hardis:generate:packagexmlfull:org",
7116
- "generate:hardis:packagexmlfull:org",
7117
- "generate:packagexmlfull:hardis:org",
7118
- "generate:packagexmlfull:org:hardis",
7119
- "hardis:org:packagexmlfull:generate",
7120
- "org:hardis:packagexmlfull:generate",
7121
- "org:packagexmlfull:hardis:generate",
7122
- "org:packagexmlfull:generate:hardis",
7123
- "hardis:packagexmlfull:org:generate",
7124
- "packagexmlfull:hardis:org:generate",
7125
- "packagexmlfull:org:hardis:generate",
7126
- "packagexmlfull:org:generate:hardis",
7127
- "hardis:packagexmlfull:generate:org",
7128
- "packagexmlfull:hardis:generate:org",
7129
- "packagexmlfull:generate:hardis:org",
7130
- "packagexmlfull:generate:org:hardis"
7131
- ]
7132
- },
7133
- "hardis:org:monitor:all": {
7134
- "aliases": [],
7135
- "args": {},
7136
- "description": "Monitor org, generate reports and sends notifications\n\nYou can disable some commands defining either a **monitoringDisable** property in `.sfdx-hardis.yml`, or a comma separated list in env variable **MONITORING_DISABLE**\n\nExample in .sfdx-hardis.yml:\n \n```yaml\nmonitoringDisable:\n - METADATA_STATUS\n - MISSING_ATTRIBUTES\n - UNUSED_METADATAS\n```\n \nExample in env var:\n\n```sh\nMONITORING_DISABLE=METADATA_STATUS,MISSING_ATTRIBUTES,UNUSED_METADATAS\n```\n\nA [default list of monitoring commands](https://sfdx-hardis.cloudity.com/salesforce-monitoring-home/#monitoring-commands) is used, if you want to override it you can define property **monitoringCommands** in your .sfdx-hardis.yml file\n\nExample:\n\n```yaml\nmonitoringCommands:\n - title: My Custom command\n command: sf my:custom:command\n - title: My Custom command 2\n command: sf my:other:custom:command\n```\n\nYou can force the daily run of all commands by defining env var `MONITORING_IGNORE_FREQUENCY=true`\n\nThe default list of commands is the following:\n\n| Key | Description | Command | Frequency |\n| :---: | :---- | :---- | :-----: |\n| [AUDIT_TRAIL](https://sfdx-hardis.cloudity.com/hardis/org/diagnose/audittrail) | Detect suspect setup actions in major org | [sf hardis:org:diagnose:audittrail](https://sfdx-hardis.cloudity.com/hardis/org/diagnose/audittrail) | daily |\n| [LEGACY_API](https://sfdx-hardis.cloudity.com/hardis/org/diagnose/legacyapi) | Detect calls to deprecated API versions | [sf hardis:org:diagnose:legacyapi](https://sfdx-hardis.cloudity.com/hardis/org/diagnose/legacyapi) | daily |\n| [ORG_LIMITS](https://sfdx-hardis.cloudity.com/hardis/org/monitor/limits) | Detect if org limits are close to be reached | [sf hardis:org:monitor:limits](https://sfdx-hardis.cloudity.com/hardis/org/monitor/limits) | daily |\n| [LICENSES](https://sfdx-hardis.cloudity.com/hardis/org/diagnose/licenses) | Extract licenses information | [sf hardis:org:diagnose:licenses](https://sfdx-hardis.cloudity.com/hardis/org/diagnose/licenses) | weekly |\n| [LINT_ACCESS](https://sfdx-hardis.cloudity.com/hardis/lint/access) | Detect custom elements with no access rights defined in permission sets | [sf hardis:lint:access](https://sfdx-hardis.cloudity.com/hardis/lint/access) | weekly |\n| [UNUSED_LICENSES](https://sfdx-hardis.cloudity.com/hardis/org/diagnose/unusedlicenses) | Detect permission set licenses that are assigned to users that do not need them | [sf hardis:org:diagnose:unusedlicenses](https://sfdx-hardis.cloudity.com/hardis/org/diagnose/unusedlicenses) | weekly |\n| [UNUSED_USERS](https://sfdx-hardis.cloudity.com/hardis/org/diagnose/unusedusers) | Detect active users without recent logins | [sf hardis:org:diagnose:unusedusers](https://sfdx-hardis.cloudity.com/hardis/org/diagnose/unusedusers) | weekly |\n| [ACTIVE_USERS](https://sfdx-hardis.cloudity.com/hardis/org/diagnose/unusedusers) | Detect active users with recent logins | [sf hardis:org:diagnose:unusedusers --returnactiveusers](https://sfdx-hardis.cloudity.com/hardis/org/diagnose/unusedusers) | weekly |\n| [ORG_INFO](https://sfdx-hardis.cloudity.com/hardis/org/diagnose/instanceupgrade) | Get org info + SF instance info + next major upgrade date | [sf hardis:org:diagnose:instanceupgrade](https://sfdx-hardis.cloudity.com/hardis/org/diagnose/instanceupgrade) | weekly |\n| [RELEASE_UPDATES](https://sfdx-hardis.cloudity.com/hardis/org/diagnose/releaseupdates) | Gather warnings about incoming and overdue Release Updates | [sf hardis:org:diagnose:releaseupdates](https://sfdx-hardis.cloudity.com/hardis/org/diagnose/releaseupdates) | weekly |\n| [UNUSED_METADATAS](https://sfdx-hardis.cloudity.com/hardis/lint/unusedmetadatas) | Detect custom labels and custom permissions that are not in use | [sf hardis:lint:unusedmetadatas](https://sfdx-hardis.cloudity.com/hardis/lint/unusedmetadatas) | weekly |\n| [UNUSED_APEX_CLASSES](https://sfdx-hardis.cloudity.com/hardis/org/diagnose/unused-apex-classes) | Detect unused Apex classes in an org | [sf hardis:org:diagnose:unused-apex-classes](https://sfdx-hardis.cloudity.com/hardis/org/diagnose/unused-apex-classes) | weekly |\n| [CONNECTED_APPS](https://sfdx-hardis.cloudity.com/hardis/org/diagnose/unused-connected-apps) | Detect unused Connected Apps in an org | [sf hardis:org:diagnose:unused-connected-apps](https://sfdx-hardis.cloudity.com/hardis/org/diagnose/unused-connected-apps) | weekly |\n| [METADATA_STATUS](https://sfdx-hardis.cloudity.com/hardis/lint/metadatastatus) | Detect inactive metadata | [sf hardis:lint:metadatastatus](https://sfdx-hardis.cloudity.com/hardis/lint/metadatastatus) | weekly |\n| [MISSING_ATTRIBUTES](https://sfdx-hardis.cloudity.com/hardis/lint/missingattributes) | Detect missing description on custom field | [sf hardis:lint:missingattributes](https://sfdx-hardis.cloudity.com/hardis/lint/missingattributes) | weekly |\n\n",
7137
- "examples": [
7138
- "$ sf hardis:org:monitor:all"
7145
+ "$ sf hardis:org:monitor:all"
7139
7146
  ],
7140
7147
  "flags": {
7141
7148
  "json": {
@@ -7605,6 +7612,113 @@
7605
7612
  "limits:monitor:org:hardis"
7606
7613
  ]
7607
7614
  },
7615
+ "hardis:org:retrieve:packageconfig": {
7616
+ "aliases": [],
7617
+ "args": {},
7618
+ "description": "\n**Retrieves the installed package configuration from a Salesforce org and optionally updates the local project configuration.**\n\nThis command is useful for maintaining an accurate record of installed packages within your Salesforce project, which is crucial for managing dependencies and ensuring consistent deployments across environments.\n\nKey functionalities:\n\n- **Package Listing:** Connects to a specified Salesforce org (or prompts for one if not provided) and retrieves a list of all installed packages.\n- **Configuration Update:** Offers the option to update your local project's configuration with the retrieved list of installed packages. This can be beneficial for automating package installations during environment setup or CI/CD processes.\n\n## Technical explanations\n\nThe command's technical implementation involves:\n\n- **Org Connection:** It establishes a connection to the target Salesforce org using the provided or prompted username.\n- **Metadata Retrieval:** It utilizes `MetadataUtils.listInstalledPackages` to query the Salesforce org and obtain details about the installed packages.\n- **Interactive Prompt:** It uses the `prompts` library to ask the user whether they want to update their local project configuration with the retrieved package list.\n- **Configuration Management:** If the user confirms, it calls `managePackageConfig` to update the project's configuration file (likely `.sfdx-hardis.yml`) with the new package information.\n- **User Feedback:** Provides clear messages to the user about the success of the package retrieval and configuration update.\n",
7619
+ "examples": [
7620
+ "$ sf hardis:org:retrieve:packageconfig",
7621
+ "sf hardis:org:retrieve:packageconfig -u myOrg"
7622
+ ],
7623
+ "flags": {
7624
+ "json": {
7625
+ "description": "Format output as json.",
7626
+ "helpGroup": "GLOBAL",
7627
+ "name": "json",
7628
+ "allowNo": false,
7629
+ "type": "boolean"
7630
+ },
7631
+ "flags-dir": {
7632
+ "helpGroup": "GLOBAL",
7633
+ "name": "flags-dir",
7634
+ "summary": "Import flag values from a directory.",
7635
+ "hasDynamicHelp": false,
7636
+ "multiple": false,
7637
+ "type": "option"
7638
+ },
7639
+ "debug": {
7640
+ "char": "d",
7641
+ "description": "Activate debug mode (more logs)",
7642
+ "name": "debug",
7643
+ "allowNo": false,
7644
+ "type": "boolean"
7645
+ },
7646
+ "websocket": {
7647
+ "description": "Websocket host:port for VsCode SFDX Hardis UI integration",
7648
+ "name": "websocket",
7649
+ "hasDynamicHelp": false,
7650
+ "multiple": false,
7651
+ "type": "option"
7652
+ },
7653
+ "skipauth": {
7654
+ "description": "Skip authentication check when a default username is required",
7655
+ "name": "skipauth",
7656
+ "allowNo": false,
7657
+ "type": "boolean"
7658
+ },
7659
+ "target-org": {
7660
+ "aliases": [
7661
+ "targetusername",
7662
+ "u"
7663
+ ],
7664
+ "char": "o",
7665
+ "deprecateAliases": true,
7666
+ "name": "target-org",
7667
+ "noCacheDefault": true,
7668
+ "required": true,
7669
+ "summary": "Username or alias of the target org. Not required if the `target-org` configuration variable is already set.",
7670
+ "hasDynamicHelp": true,
7671
+ "multiple": false,
7672
+ "type": "option"
7673
+ }
7674
+ },
7675
+ "hasDynamicHelp": true,
7676
+ "hiddenAliases": [],
7677
+ "id": "hardis:org:retrieve:packageconfig",
7678
+ "pluginAlias": "sfdx-hardis",
7679
+ "pluginName": "sfdx-hardis",
7680
+ "pluginType": "core",
7681
+ "strict": true,
7682
+ "enableJsonFlag": true,
7683
+ "title": "Retrieve package configuration from an org",
7684
+ "requiresProject": false,
7685
+ "isESM": true,
7686
+ "relativePath": [
7687
+ "lib",
7688
+ "commands",
7689
+ "hardis",
7690
+ "org",
7691
+ "retrieve",
7692
+ "packageconfig.js"
7693
+ ],
7694
+ "aliasPermutations": [],
7695
+ "permutations": [
7696
+ "hardis:org:retrieve:packageconfig",
7697
+ "org:hardis:retrieve:packageconfig",
7698
+ "org:retrieve:hardis:packageconfig",
7699
+ "org:retrieve:packageconfig:hardis",
7700
+ "hardis:retrieve:org:packageconfig",
7701
+ "retrieve:hardis:org:packageconfig",
7702
+ "retrieve:org:hardis:packageconfig",
7703
+ "retrieve:org:packageconfig:hardis",
7704
+ "hardis:retrieve:packageconfig:org",
7705
+ "retrieve:hardis:packageconfig:org",
7706
+ "retrieve:packageconfig:hardis:org",
7707
+ "retrieve:packageconfig:org:hardis",
7708
+ "hardis:org:packageconfig:retrieve",
7709
+ "org:hardis:packageconfig:retrieve",
7710
+ "org:packageconfig:hardis:retrieve",
7711
+ "org:packageconfig:retrieve:hardis",
7712
+ "hardis:packageconfig:org:retrieve",
7713
+ "packageconfig:hardis:org:retrieve",
7714
+ "packageconfig:org:hardis:retrieve",
7715
+ "packageconfig:org:retrieve:hardis",
7716
+ "hardis:packageconfig:retrieve:org",
7717
+ "packageconfig:hardis:retrieve:org",
7718
+ "packageconfig:retrieve:hardis:org",
7719
+ "packageconfig:retrieve:org:hardis"
7720
+ ]
7721
+ },
7608
7722
  "hardis:org:purge:apexlog": {
7609
7723
  "aliases": [],
7610
7724
  "args": {},
@@ -7873,113 +7987,6 @@
7873
7987
  "flow:purge:org:hardis"
7874
7988
  ]
7875
7989
  },
7876
- "hardis:org:retrieve:packageconfig": {
7877
- "aliases": [],
7878
- "args": {},
7879
- "description": "\n**Retrieves the installed package configuration from a Salesforce org and optionally updates the local project configuration.**\n\nThis command is useful for maintaining an accurate record of installed packages within your Salesforce project, which is crucial for managing dependencies and ensuring consistent deployments across environments.\n\nKey functionalities:\n\n- **Package Listing:** Connects to a specified Salesforce org (or prompts for one if not provided) and retrieves a list of all installed packages.\n- **Configuration Update:** Offers the option to update your local project's configuration with the retrieved list of installed packages. This can be beneficial for automating package installations during environment setup or CI/CD processes.\n\n## Technical explanations\n\nThe command's technical implementation involves:\n\n- **Org Connection:** It establishes a connection to the target Salesforce org using the provided or prompted username.\n- **Metadata Retrieval:** It utilizes `MetadataUtils.listInstalledPackages` to query the Salesforce org and obtain details about the installed packages.\n- **Interactive Prompt:** It uses the `prompts` library to ask the user whether they want to update their local project configuration with the retrieved package list.\n- **Configuration Management:** If the user confirms, it calls `managePackageConfig` to update the project's configuration file (likely `.sfdx-hardis.yml`) with the new package information.\n- **User Feedback:** Provides clear messages to the user about the success of the package retrieval and configuration update.\n",
7880
- "examples": [
7881
- "$ sf hardis:org:retrieve:packageconfig",
7882
- "sf hardis:org:retrieve:packageconfig -u myOrg"
7883
- ],
7884
- "flags": {
7885
- "json": {
7886
- "description": "Format output as json.",
7887
- "helpGroup": "GLOBAL",
7888
- "name": "json",
7889
- "allowNo": false,
7890
- "type": "boolean"
7891
- },
7892
- "flags-dir": {
7893
- "helpGroup": "GLOBAL",
7894
- "name": "flags-dir",
7895
- "summary": "Import flag values from a directory.",
7896
- "hasDynamicHelp": false,
7897
- "multiple": false,
7898
- "type": "option"
7899
- },
7900
- "debug": {
7901
- "char": "d",
7902
- "description": "Activate debug mode (more logs)",
7903
- "name": "debug",
7904
- "allowNo": false,
7905
- "type": "boolean"
7906
- },
7907
- "websocket": {
7908
- "description": "Websocket host:port for VsCode SFDX Hardis UI integration",
7909
- "name": "websocket",
7910
- "hasDynamicHelp": false,
7911
- "multiple": false,
7912
- "type": "option"
7913
- },
7914
- "skipauth": {
7915
- "description": "Skip authentication check when a default username is required",
7916
- "name": "skipauth",
7917
- "allowNo": false,
7918
- "type": "boolean"
7919
- },
7920
- "target-org": {
7921
- "aliases": [
7922
- "targetusername",
7923
- "u"
7924
- ],
7925
- "char": "o",
7926
- "deprecateAliases": true,
7927
- "name": "target-org",
7928
- "noCacheDefault": true,
7929
- "required": true,
7930
- "summary": "Username or alias of the target org. Not required if the `target-org` configuration variable is already set.",
7931
- "hasDynamicHelp": true,
7932
- "multiple": false,
7933
- "type": "option"
7934
- }
7935
- },
7936
- "hasDynamicHelp": true,
7937
- "hiddenAliases": [],
7938
- "id": "hardis:org:retrieve:packageconfig",
7939
- "pluginAlias": "sfdx-hardis",
7940
- "pluginName": "sfdx-hardis",
7941
- "pluginType": "core",
7942
- "strict": true,
7943
- "enableJsonFlag": true,
7944
- "title": "Retrieve package configuration from an org",
7945
- "requiresProject": false,
7946
- "isESM": true,
7947
- "relativePath": [
7948
- "lib",
7949
- "commands",
7950
- "hardis",
7951
- "org",
7952
- "retrieve",
7953
- "packageconfig.js"
7954
- ],
7955
- "aliasPermutations": [],
7956
- "permutations": [
7957
- "hardis:org:retrieve:packageconfig",
7958
- "org:hardis:retrieve:packageconfig",
7959
- "org:retrieve:hardis:packageconfig",
7960
- "org:retrieve:packageconfig:hardis",
7961
- "hardis:retrieve:org:packageconfig",
7962
- "retrieve:hardis:org:packageconfig",
7963
- "retrieve:org:hardis:packageconfig",
7964
- "retrieve:org:packageconfig:hardis",
7965
- "hardis:retrieve:packageconfig:org",
7966
- "retrieve:hardis:packageconfig:org",
7967
- "retrieve:packageconfig:hardis:org",
7968
- "retrieve:packageconfig:org:hardis",
7969
- "hardis:org:packageconfig:retrieve",
7970
- "org:hardis:packageconfig:retrieve",
7971
- "org:packageconfig:hardis:retrieve",
7972
- "org:packageconfig:retrieve:hardis",
7973
- "hardis:packageconfig:org:retrieve",
7974
- "packageconfig:hardis:org:retrieve",
7975
- "packageconfig:org:hardis:retrieve",
7976
- "packageconfig:org:retrieve:hardis",
7977
- "hardis:packageconfig:retrieve:org",
7978
- "packageconfig:hardis:retrieve:org",
7979
- "packageconfig:retrieve:hardis:org",
7980
- "packageconfig:retrieve:org:hardis"
7981
- ]
7982
- },
7983
7990
  "hardis:org:test:apex": {
7984
7991
  "aliases": [],
7985
7992
  "args": {},
@@ -9396,6 +9403,109 @@
9396
9403
  "auth:configure:project:hardis"
9397
9404
  ]
9398
9405
  },
9406
+ "hardis:project:convert:profilestopermsets": {
9407
+ "aliases": [],
9408
+ "args": {},
9409
+ "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## Technical explanations\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",
9410
+ "examples": [
9411
+ "$ sf hardis:project:convert:profilestopermsets"
9412
+ ],
9413
+ "flags": {
9414
+ "json": {
9415
+ "description": "Format output as json.",
9416
+ "helpGroup": "GLOBAL",
9417
+ "name": "json",
9418
+ "allowNo": false,
9419
+ "type": "boolean"
9420
+ },
9421
+ "flags-dir": {
9422
+ "helpGroup": "GLOBAL",
9423
+ "name": "flags-dir",
9424
+ "summary": "Import flag values from a directory.",
9425
+ "hasDynamicHelp": false,
9426
+ "multiple": false,
9427
+ "type": "option"
9428
+ },
9429
+ "except": {
9430
+ "char": "e",
9431
+ "description": "List of filters",
9432
+ "name": "except",
9433
+ "default": [],
9434
+ "hasDynamicHelp": false,
9435
+ "multiple": true,
9436
+ "type": "option"
9437
+ },
9438
+ "debug": {
9439
+ "char": "d",
9440
+ "description": "Activate debug mode (more logs)",
9441
+ "name": "debug",
9442
+ "allowNo": false,
9443
+ "type": "boolean"
9444
+ },
9445
+ "websocket": {
9446
+ "description": "Websocket host:port for VsCode SFDX Hardis UI integration",
9447
+ "name": "websocket",
9448
+ "hasDynamicHelp": false,
9449
+ "multiple": false,
9450
+ "type": "option"
9451
+ },
9452
+ "skipauth": {
9453
+ "description": "Skip authentication check when a default username is required",
9454
+ "name": "skipauth",
9455
+ "allowNo": false,
9456
+ "type": "boolean"
9457
+ }
9458
+ },
9459
+ "hasDynamicHelp": false,
9460
+ "hiddenAliases": [],
9461
+ "id": "hardis:project:convert:profilestopermsets",
9462
+ "pluginAlias": "sfdx-hardis",
9463
+ "pluginName": "sfdx-hardis",
9464
+ "pluginType": "core",
9465
+ "strict": true,
9466
+ "enableJsonFlag": true,
9467
+ "title": "Convert Profiles into Permission Sets",
9468
+ "requiresProject": true,
9469
+ "requiresSfdxPlugins": [
9470
+ "shane-sfdx-plugins"
9471
+ ],
9472
+ "isESM": true,
9473
+ "relativePath": [
9474
+ "lib",
9475
+ "commands",
9476
+ "hardis",
9477
+ "project",
9478
+ "convert",
9479
+ "profilestopermsets.js"
9480
+ ],
9481
+ "aliasPermutations": [],
9482
+ "permutations": [
9483
+ "hardis:project:convert:profilestopermsets",
9484
+ "project:hardis:convert:profilestopermsets",
9485
+ "project:convert:hardis:profilestopermsets",
9486
+ "project:convert:profilestopermsets:hardis",
9487
+ "hardis:convert:project:profilestopermsets",
9488
+ "convert:hardis:project:profilestopermsets",
9489
+ "convert:project:hardis:profilestopermsets",
9490
+ "convert:project:profilestopermsets:hardis",
9491
+ "hardis:convert:profilestopermsets:project",
9492
+ "convert:hardis:profilestopermsets:project",
9493
+ "convert:profilestopermsets:hardis:project",
9494
+ "convert:profilestopermsets:project:hardis",
9495
+ "hardis:project:profilestopermsets:convert",
9496
+ "project:hardis:profilestopermsets:convert",
9497
+ "project:profilestopermsets:hardis:convert",
9498
+ "project:profilestopermsets:convert:hardis",
9499
+ "hardis:profilestopermsets:project:convert",
9500
+ "profilestopermsets:hardis:project:convert",
9501
+ "profilestopermsets:project:hardis:convert",
9502
+ "profilestopermsets:project:convert:hardis",
9503
+ "hardis:profilestopermsets:convert:project",
9504
+ "profilestopermsets:hardis:convert:project",
9505
+ "profilestopermsets:convert:hardis:project",
9506
+ "profilestopermsets:convert:project:hardis"
9507
+ ]
9508
+ },
9399
9509
  "hardis:project:clean:emptyitems": {
9400
9510
  "aliases": [],
9401
9511
  "args": {},
@@ -10881,12 +10991,12 @@
10881
10991
  "xml:clean:project:hardis"
10882
10992
  ]
10883
10993
  },
10884
- "hardis:project:convert:profilestopermsets": {
10994
+ "hardis:project:fix:profiletabs": {
10885
10995
  "aliases": [],
10886
10996
  "args": {},
10887
- "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## Technical explanations\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",
10997
+ "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## Technical explanations\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",
10888
10998
  "examples": [
10889
- "$ sf hardis:project:convert:profilestopermsets"
10999
+ "$ sf hardis:project:fix:profiletabs"
10890
11000
  ],
10891
11001
  "flags": {
10892
11002
  "json": {
@@ -10904,13 +11014,13 @@
10904
11014
  "multiple": false,
10905
11015
  "type": "option"
10906
11016
  },
10907
- "except": {
10908
- "char": "e",
10909
- "description": "List of filters",
10910
- "name": "except",
10911
- "default": [],
11017
+ "path": {
11018
+ "char": "p",
11019
+ "description": "Root folder",
11020
+ "name": "path",
11021
+ "default": "/home/runner/work/sfdx-hardis/sfdx-hardis",
10912
11022
  "hasDynamicHelp": false,
10913
- "multiple": true,
11023
+ "multiple": false,
10914
11024
  "type": "option"
10915
11025
  },
10916
11026
  "debug": {
@@ -10932,56 +11042,168 @@
10932
11042
  "name": "skipauth",
10933
11043
  "allowNo": false,
10934
11044
  "type": "boolean"
11045
+ },
11046
+ "target-org": {
11047
+ "aliases": [
11048
+ "targetusername",
11049
+ "u"
11050
+ ],
11051
+ "char": "o",
11052
+ "deprecateAliases": true,
11053
+ "name": "target-org",
11054
+ "noCacheDefault": true,
11055
+ "required": true,
11056
+ "summary": "Username or alias of the target org. Not required if the `target-org` configuration variable is already set.",
11057
+ "hasDynamicHelp": true,
11058
+ "multiple": false,
11059
+ "type": "option"
10935
11060
  }
10936
11061
  },
10937
- "hasDynamicHelp": false,
11062
+ "hasDynamicHelp": true,
10938
11063
  "hiddenAliases": [],
10939
- "id": "hardis:project:convert:profilestopermsets",
11064
+ "id": "hardis:project:fix:profiletabs",
10940
11065
  "pluginAlias": "sfdx-hardis",
10941
11066
  "pluginName": "sfdx-hardis",
10942
11067
  "pluginType": "core",
10943
11068
  "strict": true,
10944
11069
  "enableJsonFlag": true,
10945
- "title": "Convert Profiles into Permission Sets",
11070
+ "title": "Fix profiles to add tabs that are not retrieved by SF CLI",
10946
11071
  "requiresProject": true,
10947
- "requiresSfdxPlugins": [
10948
- "shane-sfdx-plugins"
10949
- ],
10950
11072
  "isESM": true,
10951
11073
  "relativePath": [
10952
11074
  "lib",
10953
11075
  "commands",
10954
11076
  "hardis",
10955
11077
  "project",
10956
- "convert",
10957
- "profilestopermsets.js"
11078
+ "fix",
11079
+ "profiletabs.js"
10958
11080
  ],
10959
11081
  "aliasPermutations": [],
10960
11082
  "permutations": [
10961
- "hardis:project:convert:profilestopermsets",
10962
- "project:hardis:convert:profilestopermsets",
10963
- "project:convert:hardis:profilestopermsets",
10964
- "project:convert:profilestopermsets:hardis",
10965
- "hardis:convert:project:profilestopermsets",
10966
- "convert:hardis:project:profilestopermsets",
10967
- "convert:project:hardis:profilestopermsets",
10968
- "convert:project:profilestopermsets:hardis",
10969
- "hardis:convert:profilestopermsets:project",
10970
- "convert:hardis:profilestopermsets:project",
10971
- "convert:profilestopermsets:hardis:project",
10972
- "convert:profilestopermsets:project:hardis",
10973
- "hardis:project:profilestopermsets:convert",
10974
- "project:hardis:profilestopermsets:convert",
10975
- "project:profilestopermsets:hardis:convert",
10976
- "project:profilestopermsets:convert:hardis",
10977
- "hardis:profilestopermsets:project:convert",
10978
- "profilestopermsets:hardis:project:convert",
10979
- "profilestopermsets:project:hardis:convert",
10980
- "profilestopermsets:project:convert:hardis",
10981
- "hardis:profilestopermsets:convert:project",
10982
- "profilestopermsets:hardis:convert:project",
10983
- "profilestopermsets:convert:hardis:project",
10984
- "profilestopermsets:convert:project:hardis"
11083
+ "hardis:project:fix:profiletabs",
11084
+ "project:hardis:fix:profiletabs",
11085
+ "project:fix:hardis:profiletabs",
11086
+ "project:fix:profiletabs:hardis",
11087
+ "hardis:fix:project:profiletabs",
11088
+ "fix:hardis:project:profiletabs",
11089
+ "fix:project:hardis:profiletabs",
11090
+ "fix:project:profiletabs:hardis",
11091
+ "hardis:fix:profiletabs:project",
11092
+ "fix:hardis:profiletabs:project",
11093
+ "fix:profiletabs:hardis:project",
11094
+ "fix:profiletabs:project:hardis",
11095
+ "hardis:project:profiletabs:fix",
11096
+ "project:hardis:profiletabs:fix",
11097
+ "project:profiletabs:hardis:fix",
11098
+ "project:profiletabs:fix:hardis",
11099
+ "hardis:profiletabs:project:fix",
11100
+ "profiletabs:hardis:project:fix",
11101
+ "profiletabs:project:hardis:fix",
11102
+ "profiletabs:project:fix:hardis",
11103
+ "hardis:profiletabs:fix:project",
11104
+ "profiletabs:hardis:fix:project",
11105
+ "profiletabs:fix:hardis:project",
11106
+ "profiletabs:fix:project:hardis"
11107
+ ]
11108
+ },
11109
+ "hardis:project:fix:v53flexipages": {
11110
+ "aliases": [],
11111
+ "args": {},
11112
+ "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## Technical explanations\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",
11113
+ "examples": [
11114
+ "$ sf hardis:project:fix:v53flexipages"
11115
+ ],
11116
+ "flags": {
11117
+ "json": {
11118
+ "description": "Format output as json.",
11119
+ "helpGroup": "GLOBAL",
11120
+ "name": "json",
11121
+ "allowNo": false,
11122
+ "type": "boolean"
11123
+ },
11124
+ "flags-dir": {
11125
+ "helpGroup": "GLOBAL",
11126
+ "name": "flags-dir",
11127
+ "summary": "Import flag values from a directory.",
11128
+ "hasDynamicHelp": false,
11129
+ "multiple": false,
11130
+ "type": "option"
11131
+ },
11132
+ "path": {
11133
+ "char": "p",
11134
+ "description": "Root folder",
11135
+ "name": "path",
11136
+ "default": "/home/runner/work/sfdx-hardis/sfdx-hardis",
11137
+ "hasDynamicHelp": false,
11138
+ "multiple": false,
11139
+ "type": "option"
11140
+ },
11141
+ "debug": {
11142
+ "char": "d",
11143
+ "description": "Activate debug mode (more logs)",
11144
+ "name": "debug",
11145
+ "allowNo": false,
11146
+ "type": "boolean"
11147
+ },
11148
+ "websocket": {
11149
+ "description": "Websocket host:port for VsCode SFDX Hardis UI integration",
11150
+ "name": "websocket",
11151
+ "hasDynamicHelp": false,
11152
+ "multiple": false,
11153
+ "type": "option"
11154
+ },
11155
+ "skipauth": {
11156
+ "description": "Skip authentication check when a default username is required",
11157
+ "name": "skipauth",
11158
+ "allowNo": false,
11159
+ "type": "boolean"
11160
+ }
11161
+ },
11162
+ "hasDynamicHelp": false,
11163
+ "hiddenAliases": [],
11164
+ "id": "hardis:project:fix:v53flexipages",
11165
+ "pluginAlias": "sfdx-hardis",
11166
+ "pluginName": "sfdx-hardis",
11167
+ "pluginType": "core",
11168
+ "strict": true,
11169
+ "enableJsonFlag": true,
11170
+ "title": "Fix flexipages for v53",
11171
+ "requiresProject": true,
11172
+ "isESM": true,
11173
+ "relativePath": [
11174
+ "lib",
11175
+ "commands",
11176
+ "hardis",
11177
+ "project",
11178
+ "fix",
11179
+ "v53flexipages.js"
11180
+ ],
11181
+ "aliasPermutations": [],
11182
+ "permutations": [
11183
+ "hardis:project:fix:v53flexipages",
11184
+ "project:hardis:fix:v53flexipages",
11185
+ "project:fix:hardis:v53flexipages",
11186
+ "project:fix:v53flexipages:hardis",
11187
+ "hardis:fix:project:v53flexipages",
11188
+ "fix:hardis:project:v53flexipages",
11189
+ "fix:project:hardis:v53flexipages",
11190
+ "fix:project:v53flexipages:hardis",
11191
+ "hardis:fix:v53flexipages:project",
11192
+ "fix:hardis:v53flexipages:project",
11193
+ "fix:v53flexipages:hardis:project",
11194
+ "fix:v53flexipages:project:hardis",
11195
+ "hardis:project:v53flexipages:fix",
11196
+ "project:hardis:v53flexipages:fix",
11197
+ "project:v53flexipages:hardis:fix",
11198
+ "project:v53flexipages:fix:hardis",
11199
+ "hardis:v53flexipages:project:fix",
11200
+ "v53flexipages:hardis:project:fix",
11201
+ "v53flexipages:project:hardis:fix",
11202
+ "v53flexipages:project:fix:hardis",
11203
+ "hardis:v53flexipages:fix:project",
11204
+ "v53flexipages:hardis:fix:project",
11205
+ "v53flexipages:fix:hardis:project",
11206
+ "v53flexipages:fix:project:hardis"
10985
11207
  ]
10986
11208
  },
10987
11209
  "hardis:project:deploy:notify": {
@@ -12159,221 +12381,6 @@
12159
12381
  "validate:deploy:project:hardis"
12160
12382
  ]
12161
12383
  },
12162
- "hardis:project:fix:profiletabs": {
12163
- "aliases": [],
12164
- "args": {},
12165
- "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## Technical explanations\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",
12166
- "examples": [
12167
- "$ sf hardis:project:fix:profiletabs"
12168
- ],
12169
- "flags": {
12170
- "json": {
12171
- "description": "Format output as json.",
12172
- "helpGroup": "GLOBAL",
12173
- "name": "json",
12174
- "allowNo": false,
12175
- "type": "boolean"
12176
- },
12177
- "flags-dir": {
12178
- "helpGroup": "GLOBAL",
12179
- "name": "flags-dir",
12180
- "summary": "Import flag values from a directory.",
12181
- "hasDynamicHelp": false,
12182
- "multiple": false,
12183
- "type": "option"
12184
- },
12185
- "path": {
12186
- "char": "p",
12187
- "description": "Root folder",
12188
- "name": "path",
12189
- "default": "/home/runner/work/sfdx-hardis/sfdx-hardis",
12190
- "hasDynamicHelp": false,
12191
- "multiple": false,
12192
- "type": "option"
12193
- },
12194
- "debug": {
12195
- "char": "d",
12196
- "description": "Activate debug mode (more logs)",
12197
- "name": "debug",
12198
- "allowNo": false,
12199
- "type": "boolean"
12200
- },
12201
- "websocket": {
12202
- "description": "Websocket host:port for VsCode SFDX Hardis UI integration",
12203
- "name": "websocket",
12204
- "hasDynamicHelp": false,
12205
- "multiple": false,
12206
- "type": "option"
12207
- },
12208
- "skipauth": {
12209
- "description": "Skip authentication check when a default username is required",
12210
- "name": "skipauth",
12211
- "allowNo": false,
12212
- "type": "boolean"
12213
- },
12214
- "target-org": {
12215
- "aliases": [
12216
- "targetusername",
12217
- "u"
12218
- ],
12219
- "char": "o",
12220
- "deprecateAliases": true,
12221
- "name": "target-org",
12222
- "noCacheDefault": true,
12223
- "required": true,
12224
- "summary": "Username or alias of the target org. Not required if the `target-org` configuration variable is already set.",
12225
- "hasDynamicHelp": true,
12226
- "multiple": false,
12227
- "type": "option"
12228
- }
12229
- },
12230
- "hasDynamicHelp": true,
12231
- "hiddenAliases": [],
12232
- "id": "hardis:project:fix:profiletabs",
12233
- "pluginAlias": "sfdx-hardis",
12234
- "pluginName": "sfdx-hardis",
12235
- "pluginType": "core",
12236
- "strict": true,
12237
- "enableJsonFlag": true,
12238
- "title": "Fix profiles to add tabs that are not retrieved by SF CLI",
12239
- "requiresProject": true,
12240
- "isESM": true,
12241
- "relativePath": [
12242
- "lib",
12243
- "commands",
12244
- "hardis",
12245
- "project",
12246
- "fix",
12247
- "profiletabs.js"
12248
- ],
12249
- "aliasPermutations": [],
12250
- "permutations": [
12251
- "hardis:project:fix:profiletabs",
12252
- "project:hardis:fix:profiletabs",
12253
- "project:fix:hardis:profiletabs",
12254
- "project:fix:profiletabs:hardis",
12255
- "hardis:fix:project:profiletabs",
12256
- "fix:hardis:project:profiletabs",
12257
- "fix:project:hardis:profiletabs",
12258
- "fix:project:profiletabs:hardis",
12259
- "hardis:fix:profiletabs:project",
12260
- "fix:hardis:profiletabs:project",
12261
- "fix:profiletabs:hardis:project",
12262
- "fix:profiletabs:project:hardis",
12263
- "hardis:project:profiletabs:fix",
12264
- "project:hardis:profiletabs:fix",
12265
- "project:profiletabs:hardis:fix",
12266
- "project:profiletabs:fix:hardis",
12267
- "hardis:profiletabs:project:fix",
12268
- "profiletabs:hardis:project:fix",
12269
- "profiletabs:project:hardis:fix",
12270
- "profiletabs:project:fix:hardis",
12271
- "hardis:profiletabs:fix:project",
12272
- "profiletabs:hardis:fix:project",
12273
- "profiletabs:fix:hardis:project",
12274
- "profiletabs:fix:project:hardis"
12275
- ]
12276
- },
12277
- "hardis:project:fix:v53flexipages": {
12278
- "aliases": [],
12279
- "args": {},
12280
- "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## Technical explanations\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",
12281
- "examples": [
12282
- "$ sf hardis:project:fix:v53flexipages"
12283
- ],
12284
- "flags": {
12285
- "json": {
12286
- "description": "Format output as json.",
12287
- "helpGroup": "GLOBAL",
12288
- "name": "json",
12289
- "allowNo": false,
12290
- "type": "boolean"
12291
- },
12292
- "flags-dir": {
12293
- "helpGroup": "GLOBAL",
12294
- "name": "flags-dir",
12295
- "summary": "Import flag values from a directory.",
12296
- "hasDynamicHelp": false,
12297
- "multiple": false,
12298
- "type": "option"
12299
- },
12300
- "path": {
12301
- "char": "p",
12302
- "description": "Root folder",
12303
- "name": "path",
12304
- "default": "/home/runner/work/sfdx-hardis/sfdx-hardis",
12305
- "hasDynamicHelp": false,
12306
- "multiple": false,
12307
- "type": "option"
12308
- },
12309
- "debug": {
12310
- "char": "d",
12311
- "description": "Activate debug mode (more logs)",
12312
- "name": "debug",
12313
- "allowNo": false,
12314
- "type": "boolean"
12315
- },
12316
- "websocket": {
12317
- "description": "Websocket host:port for VsCode SFDX Hardis UI integration",
12318
- "name": "websocket",
12319
- "hasDynamicHelp": false,
12320
- "multiple": false,
12321
- "type": "option"
12322
- },
12323
- "skipauth": {
12324
- "description": "Skip authentication check when a default username is required",
12325
- "name": "skipauth",
12326
- "allowNo": false,
12327
- "type": "boolean"
12328
- }
12329
- },
12330
- "hasDynamicHelp": false,
12331
- "hiddenAliases": [],
12332
- "id": "hardis:project:fix:v53flexipages",
12333
- "pluginAlias": "sfdx-hardis",
12334
- "pluginName": "sfdx-hardis",
12335
- "pluginType": "core",
12336
- "strict": true,
12337
- "enableJsonFlag": true,
12338
- "title": "Fix flexipages for v53",
12339
- "requiresProject": true,
12340
- "isESM": true,
12341
- "relativePath": [
12342
- "lib",
12343
- "commands",
12344
- "hardis",
12345
- "project",
12346
- "fix",
12347
- "v53flexipages.js"
12348
- ],
12349
- "aliasPermutations": [],
12350
- "permutations": [
12351
- "hardis:project:fix:v53flexipages",
12352
- "project:hardis:fix:v53flexipages",
12353
- "project:fix:hardis:v53flexipages",
12354
- "project:fix:v53flexipages:hardis",
12355
- "hardis:fix:project:v53flexipages",
12356
- "fix:hardis:project:v53flexipages",
12357
- "fix:project:hardis:v53flexipages",
12358
- "fix:project:v53flexipages:hardis",
12359
- "hardis:fix:v53flexipages:project",
12360
- "fix:hardis:v53flexipages:project",
12361
- "fix:v53flexipages:hardis:project",
12362
- "fix:v53flexipages:project:hardis",
12363
- "hardis:project:v53flexipages:fix",
12364
- "project:hardis:v53flexipages:fix",
12365
- "project:v53flexipages:hardis:fix",
12366
- "project:v53flexipages:fix:hardis",
12367
- "hardis:v53flexipages:project:fix",
12368
- "v53flexipages:hardis:project:fix",
12369
- "v53flexipages:project:hardis:fix",
12370
- "v53flexipages:project:fix:hardis",
12371
- "hardis:v53flexipages:fix:project",
12372
- "v53flexipages:hardis:fix:project",
12373
- "v53flexipages:fix:hardis:project",
12374
- "v53flexipages:fix:project:hardis"
12375
- ]
12376
- },
12377
12384
  "hardis:project:generate:bypass": {
12378
12385
  "aliases": [],
12379
12386
  "args": {},
@@ -14856,5 +14863,5 @@
14856
14863
  ]
14857
14864
  }
14858
14865
  },
14859
- "version": "6.0.4-beta202508121754.0"
14866
+ "version": "6.0.4-beta202508131002.0"
14860
14867
  }