sfdx-hardis 6.12.1 → 6.12.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +11 -0
- package/lib/commands/hardis/project/deploy/smart.js +2 -0
- package/lib/commands/hardis/project/deploy/smart.js.map +1 -1
- package/lib/common/actionsProvider/actionsProvider.js +4 -1
- package/lib/common/actionsProvider/actionsProvider.js.map +1 -1
- package/lib/common/gitProvider/azureDevops.js +1 -1
- package/lib/common/gitProvider/azureDevops.js.map +1 -1
- package/lib/common/gitProvider/gitlab.js +60 -9
- package/lib/common/gitProvider/gitlab.js.map +1 -1
- package/lib/common/utils/apiUtils.js +4 -1
- package/lib/common/utils/apiUtils.js.map +1 -1
- package/lib/common/utils/prePostCommandUtils.js +29 -5
- package/lib/common/utils/prePostCommandUtils.js.map +1 -1
- package/oclif.lock +55 -55
- package/oclif.manifest.json +706 -706
- package/package.json +5 -5
package/oclif.manifest.json
CHANGED
|
@@ -57,12 +57,13 @@
|
|
|
57
57
|
"world:hello"
|
|
58
58
|
]
|
|
59
59
|
},
|
|
60
|
-
"hardis:
|
|
60
|
+
"hardis:auth:login": {
|
|
61
61
|
"aliases": [],
|
|
62
62
|
"args": {},
|
|
63
|
-
"description": "\n## Command Behavior\n\n**
|
|
63
|
+
"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<details markdown=\"1\">\n<summary>Technical explanations</summary>\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</details>\n",
|
|
64
64
|
"examples": [
|
|
65
|
-
"$ sf hardis:
|
|
65
|
+
"$ sf hardis:auth:login",
|
|
66
|
+
"CI=true CI_COMMIT_REF_NAME=monitoring_myclient sf hardis:auth:login"
|
|
66
67
|
],
|
|
67
68
|
"flags": {
|
|
68
69
|
"json": {
|
|
@@ -80,6 +81,28 @@
|
|
|
80
81
|
"multiple": false,
|
|
81
82
|
"type": "option"
|
|
82
83
|
},
|
|
84
|
+
"instanceurl": {
|
|
85
|
+
"char": "r",
|
|
86
|
+
"description": "URL of org instance",
|
|
87
|
+
"name": "instanceurl",
|
|
88
|
+
"hasDynamicHelp": false,
|
|
89
|
+
"multiple": false,
|
|
90
|
+
"type": "option"
|
|
91
|
+
},
|
|
92
|
+
"devhub": {
|
|
93
|
+
"char": "h",
|
|
94
|
+
"description": "Also connect associated DevHub",
|
|
95
|
+
"name": "devhub",
|
|
96
|
+
"allowNo": false,
|
|
97
|
+
"type": "boolean"
|
|
98
|
+
},
|
|
99
|
+
"scratchorg": {
|
|
100
|
+
"char": "s",
|
|
101
|
+
"description": "Scratch org",
|
|
102
|
+
"name": "scratchorg",
|
|
103
|
+
"allowNo": false,
|
|
104
|
+
"type": "boolean"
|
|
105
|
+
},
|
|
83
106
|
"debug": {
|
|
84
107
|
"char": "d",
|
|
85
108
|
"description": "Activate debug mode (more logs)",
|
|
@@ -103,42 +126,38 @@
|
|
|
103
126
|
},
|
|
104
127
|
"hasDynamicHelp": false,
|
|
105
128
|
"hiddenAliases": [],
|
|
106
|
-
"id": "hardis:
|
|
129
|
+
"id": "hardis:auth:login",
|
|
107
130
|
"pluginAlias": "sfdx-hardis",
|
|
108
131
|
"pluginName": "sfdx-hardis",
|
|
109
132
|
"pluginType": "core",
|
|
110
133
|
"strict": true,
|
|
111
134
|
"enableJsonFlag": true,
|
|
112
|
-
"title": "
|
|
113
|
-
"uiConfig": {
|
|
114
|
-
"hide": true
|
|
115
|
-
},
|
|
135
|
+
"title": "Login",
|
|
116
136
|
"requiresProject": false,
|
|
117
137
|
"isESM": true,
|
|
118
138
|
"relativePath": [
|
|
119
139
|
"lib",
|
|
120
140
|
"commands",
|
|
121
141
|
"hardis",
|
|
122
|
-
"
|
|
123
|
-
"
|
|
142
|
+
"auth",
|
|
143
|
+
"login.js"
|
|
124
144
|
],
|
|
125
145
|
"aliasPermutations": [],
|
|
126
146
|
"permutations": [
|
|
127
|
-
"hardis:
|
|
128
|
-
"
|
|
129
|
-
"
|
|
130
|
-
"hardis:
|
|
131
|
-
"
|
|
132
|
-
"
|
|
147
|
+
"hardis:auth:login",
|
|
148
|
+
"auth:hardis:login",
|
|
149
|
+
"auth:login:hardis",
|
|
150
|
+
"hardis:login:auth",
|
|
151
|
+
"login:hardis:auth",
|
|
152
|
+
"login:auth:hardis"
|
|
133
153
|
]
|
|
134
154
|
},
|
|
135
|
-
"hardis:
|
|
155
|
+
"hardis:cache:clear": {
|
|
136
156
|
"aliases": [],
|
|
137
157
|
"args": {},
|
|
138
|
-
"description": "\n## Command Behavior\n\n**
|
|
158
|
+
"description": "\n## Command Behavior\n\n**Clears the local cache generated by the sfdx-hardis plugin.**\n\nThis command is designed to remove temporary files, stored configurations, and other cached data that sfdx-hardis uses to optimize its operations. Clearing the cache can be beneficial for:\n\n- **Troubleshooting:** Resolving unexpected behavior or inconsistencies.\n- **Disk Space Management:** Freeing up storage on your local machine.\n- **Ensuring Fresh Data:** Guaranteeing that the plugin operates with the most current data and configurations.\n\n## Technical explanations\n\nThe command's technical implementation is straightforward:\n\n- **Direct Function Call:** It directly invokes the `clearCache()` function, which is imported from \buri../../../common/cache/index.js\buri.\n- **Cache Management Logic:** The \buriclearCache()` function encapsulates the logic for identifying and removing the specific files and directories that constitute the sfdx-hardis cache.\n",
|
|
139
159
|
"examples": [
|
|
140
|
-
"$ sf hardis:
|
|
141
|
-
"CI=true CI_COMMIT_REF_NAME=monitoring_myclient sf hardis:auth:login"
|
|
160
|
+
"$ sf hardis:cache:clear"
|
|
142
161
|
],
|
|
143
162
|
"flags": {
|
|
144
163
|
"json": {
|
|
@@ -156,28 +175,6 @@
|
|
|
156
175
|
"multiple": false,
|
|
157
176
|
"type": "option"
|
|
158
177
|
},
|
|
159
|
-
"instanceurl": {
|
|
160
|
-
"char": "r",
|
|
161
|
-
"description": "URL of org instance",
|
|
162
|
-
"name": "instanceurl",
|
|
163
|
-
"hasDynamicHelp": false,
|
|
164
|
-
"multiple": false,
|
|
165
|
-
"type": "option"
|
|
166
|
-
},
|
|
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
178
|
"debug": {
|
|
182
179
|
"char": "d",
|
|
183
180
|
"description": "Activate debug mode (more logs)",
|
|
@@ -201,30 +198,33 @@
|
|
|
201
198
|
},
|
|
202
199
|
"hasDynamicHelp": false,
|
|
203
200
|
"hiddenAliases": [],
|
|
204
|
-
"id": "hardis:
|
|
201
|
+
"id": "hardis:cache:clear",
|
|
205
202
|
"pluginAlias": "sfdx-hardis",
|
|
206
203
|
"pluginName": "sfdx-hardis",
|
|
207
204
|
"pluginType": "core",
|
|
208
205
|
"strict": true,
|
|
209
206
|
"enableJsonFlag": true,
|
|
210
|
-
"title": "
|
|
207
|
+
"title": "Clear sfdx-hardis cache",
|
|
208
|
+
"uiConfig": {
|
|
209
|
+
"hide": true
|
|
210
|
+
},
|
|
211
211
|
"requiresProject": false,
|
|
212
212
|
"isESM": true,
|
|
213
213
|
"relativePath": [
|
|
214
214
|
"lib",
|
|
215
215
|
"commands",
|
|
216
216
|
"hardis",
|
|
217
|
-
"
|
|
218
|
-
"
|
|
217
|
+
"cache",
|
|
218
|
+
"clear.js"
|
|
219
219
|
],
|
|
220
220
|
"aliasPermutations": [],
|
|
221
221
|
"permutations": [
|
|
222
|
-
"hardis:
|
|
223
|
-
"
|
|
224
|
-
"
|
|
225
|
-
"hardis:
|
|
226
|
-
"
|
|
227
|
-
"
|
|
222
|
+
"hardis:cache:clear",
|
|
223
|
+
"cache:hardis:clear",
|
|
224
|
+
"cache:clear:hardis",
|
|
225
|
+
"hardis:clear:cache",
|
|
226
|
+
"clear:hardis:cache",
|
|
227
|
+
"clear:cache:hardis"
|
|
228
228
|
]
|
|
229
229
|
},
|
|
230
230
|
"hardis:config:get": {
|
|
@@ -5539,12 +5539,15 @@
|
|
|
5539
5539
|
"import:data:org:hardis"
|
|
5540
5540
|
]
|
|
5541
5541
|
},
|
|
5542
|
-
"hardis:org:
|
|
5542
|
+
"hardis:org:diagnose:audittrail": {
|
|
5543
5543
|
"aliases": [],
|
|
5544
5544
|
"args": {},
|
|
5545
|
-
"description": "
|
|
5545
|
+
"description": "Export Audit trail into a CSV file with selected criteria, and highlight suspect actions\n\nAlso detects updates of Custom Settings values (disable by defining `SKIP_AUDIT_TRAIL_CUSTOM_SETTINGS=true`)\n\nRegular setup actions performed in major orgs are filtered.\n\n- \"\"\n - createScratchOrg\n - changedsenderemail\n - deleteScratchOrg\n - loginasgrantedtopartnerbt\n- Certificate and Key Management\n - insertCertificate\n- Custom App Licenses\n - addeduserpackagelicense\n - granteduserpackagelicense\n - revokeduserpackagelicense\n- Customer Portal\n - createdcustomersuccessuser\n - CSPUserDisabled\n- Currency\n - updateddatedexchrate\n- Data Management\n - queueMembership\n- Email Administration\n - dkimRotationPreparationSuccessful\n - dkimRotationSuccessful\n- External Objects\n - xdsEncryptedFieldChange\n- Groups\n - groupMembership\n- Holidays\n - holiday_insert\n- Inbox mobile and legacy desktop apps\n - enableSIQUserNonEAC\n - siqUserAcceptedTOS\n- Manage Users\n - activateduser\n - createduser\n - changedcommunitynickname\n - changedemail\n - changedfederationid\n - changedpassword\n - changedinteractionuseroffon\n - changedinteractionuseronoff\n - changedmarketinguseroffon\n - changedmarketinguseronoff\n - changedofflineuseroffon\n - changedprofileforuserstdtostd\n - changedprofileforuser\n - changedprofileforusercusttostd\n - changedprofileforuserstdtocust\n - changedroleforusertonone\n - changedroleforuser\n - changedroleforuserfromnone\n - changedUserAdminVerifiedStatusVerified\n - changedUserEmailVerifiedStatusUnverified\n - changedUserEmailVerifiedStatusVerified\n - changedknowledgeuseroffon\n - changedsfcontentuseroffon\n - changedsupportuseroffon\n - changedusername\n - changedUserPhoneNumber\n - changedUserPhoneVerifiedStatusUnverified\n - changedUserPhoneVerifiedStatusVerified\n - deactivateduser\n - deleteAuthenticatorPairing\n - deleteTwoFactorInfo2\n - deleteTwoFactorTempCode\n - frozeuser\n - insertAuthenticatorPairing\n - insertTwoFactorInfo2\n - insertTwoFactorTempCode\n - lightningloginenroll\n - PermSetAssign\n - PermSetGroupAssign\n - PermSetGroupUnassign\n - PermSetLicenseAssign\n - PermSetUnassign\n - PermSetLicenseUnassign\n - registeredUserPhoneNumber\n - resetpassword\n - suNetworkAdminLogin\n - suNetworkAdminLogout\n - suOrgAdminLogin\n - suOrgAdminLogout\n - unfrozeuser\n - useremailchangesent\n- Mobile Administration\n - assigneduserstomobileconfig\n- Reporting Snapshots\n - createdReportJob\n - deletedReportJob\n- Sandboxes\n - DeleteSandbox\n\nBy default, deployment user defined in .sfdx-hardis.yml targetUsername property will be excluded.\n\nYou can define additional users to exclude in .sfdx-hardis.yml **monitoringExcludeUsernames** property.\n\nYou can also add more sections / actions considered as not suspect using property **monitoringAllowedSectionsActions**\n\nExample:\n\n```yaml\nmonitoringExcludeUsernames:\n - deploymentuser@cloudity.com\n - marketingcloud@cloudity.com\n - integration-user@cloudity.com\n\nmonitoringAllowedSectionsActions:\n \"Some section\": [] // Will ignore all actions from such section\n \"Some other section\": [\"actionType1\",\"actionType2\",\"actionType3\"] // Will ignore only those 3 actions from section \"Some other section\". Other actions in the same section will be considered as suspect.\n```\n\n## Excel output example\n\n\n\n## Local output example\n\n\n\nThis command is part of [sfdx-hardis Monitoring](https://sfdx-hardis.cloudity.com/salesforce-monitoring-suspect-audit-trail/) and can output Grafana, Slack and MsTeams Notifications.\n",
|
|
5546
5546
|
"examples": [
|
|
5547
|
-
"$ sf hardis:org:
|
|
5547
|
+
"$ sf hardis:org:diagnose:audittrail",
|
|
5548
|
+
"$ sf hardis:org:diagnose:audittrail --excludeusers baptiste@titi.com",
|
|
5549
|
+
"$ sf hardis:org:diagnose:audittrail --excludeusers baptiste@titi.com,bertrand@titi.com",
|
|
5550
|
+
"$ sf hardis:org:diagnose:audittrail --lastndays 5"
|
|
5548
5551
|
],
|
|
5549
5552
|
"flags": {
|
|
5550
5553
|
"json": {
|
|
@@ -5562,48 +5565,30 @@
|
|
|
5562
5565
|
"multiple": false,
|
|
5563
5566
|
"type": "option"
|
|
5564
5567
|
},
|
|
5565
|
-
"
|
|
5566
|
-
"char": "
|
|
5567
|
-
"description": "
|
|
5568
|
-
"name": "
|
|
5569
|
-
"hasDynamicHelp": false,
|
|
5570
|
-
"multiple": false,
|
|
5571
|
-
"type": "option"
|
|
5572
|
-
},
|
|
5573
|
-
"chunksize": {
|
|
5574
|
-
"char": "c",
|
|
5575
|
-
"description": "Number of records to add in a chunk before it is processed",
|
|
5576
|
-
"name": "chunksize",
|
|
5577
|
-
"default": 1000,
|
|
5568
|
+
"excludeusers": {
|
|
5569
|
+
"char": "e",
|
|
5570
|
+
"description": "Comma-separated list of usernames to exclude",
|
|
5571
|
+
"name": "excludeusers",
|
|
5578
5572
|
"hasDynamicHelp": false,
|
|
5579
5573
|
"multiple": false,
|
|
5580
5574
|
"type": "option"
|
|
5581
5575
|
},
|
|
5582
|
-
"
|
|
5576
|
+
"lastndays": {
|
|
5583
5577
|
"char": "t",
|
|
5584
|
-
"description": "
|
|
5585
|
-
"name": "
|
|
5586
|
-
"default": 300000,
|
|
5578
|
+
"description": "Number of days to extract from today (included)",
|
|
5579
|
+
"name": "lastndays",
|
|
5587
5580
|
"hasDynamicHelp": false,
|
|
5588
5581
|
"multiple": false,
|
|
5589
5582
|
"type": "option"
|
|
5590
5583
|
},
|
|
5591
|
-
"
|
|
5592
|
-
"char": "
|
|
5593
|
-
"description": "
|
|
5594
|
-
"name": "
|
|
5595
|
-
"default": 0,
|
|
5584
|
+
"outputfile": {
|
|
5585
|
+
"char": "f",
|
|
5586
|
+
"description": "Force the path and name of output report file. Must end with .csv",
|
|
5587
|
+
"name": "outputfile",
|
|
5596
5588
|
"hasDynamicHelp": false,
|
|
5597
5589
|
"multiple": false,
|
|
5598
5590
|
"type": "option"
|
|
5599
5591
|
},
|
|
5600
|
-
"resume": {
|
|
5601
|
-
"char": "r",
|
|
5602
|
-
"description": "Resume previous export by checking existing files (default in CI)",
|
|
5603
|
-
"name": "resume",
|
|
5604
|
-
"allowNo": false,
|
|
5605
|
-
"type": "boolean"
|
|
5606
|
-
},
|
|
5607
5592
|
"debug": {
|
|
5608
5593
|
"char": "d",
|
|
5609
5594
|
"description": "Activate debug mode (more logs)",
|
|
@@ -5642,13 +5627,13 @@
|
|
|
5642
5627
|
},
|
|
5643
5628
|
"hasDynamicHelp": true,
|
|
5644
5629
|
"hiddenAliases": [],
|
|
5645
|
-
"id": "hardis:org:
|
|
5630
|
+
"id": "hardis:org:diagnose:audittrail",
|
|
5646
5631
|
"pluginAlias": "sfdx-hardis",
|
|
5647
5632
|
"pluginName": "sfdx-hardis",
|
|
5648
5633
|
"pluginType": "core",
|
|
5649
5634
|
"strict": true,
|
|
5650
5635
|
"enableJsonFlag": true,
|
|
5651
|
-
"title": "
|
|
5636
|
+
"title": "Diagnose content of Setup Audit Trail",
|
|
5652
5637
|
"requiresProject": false,
|
|
5653
5638
|
"isESM": true,
|
|
5654
5639
|
"relativePath": [
|
|
@@ -5656,43 +5641,43 @@
|
|
|
5656
5641
|
"commands",
|
|
5657
5642
|
"hardis",
|
|
5658
5643
|
"org",
|
|
5659
|
-
"
|
|
5660
|
-
"
|
|
5644
|
+
"diagnose",
|
|
5645
|
+
"audittrail.js"
|
|
5661
5646
|
],
|
|
5662
5647
|
"aliasPermutations": [],
|
|
5663
5648
|
"permutations": [
|
|
5664
|
-
"hardis:org:
|
|
5665
|
-
"org:hardis:
|
|
5666
|
-
"org:
|
|
5667
|
-
"org:
|
|
5668
|
-
"hardis:
|
|
5669
|
-
"
|
|
5670
|
-
"
|
|
5671
|
-
"
|
|
5672
|
-
"hardis:
|
|
5673
|
-
"
|
|
5674
|
-
"
|
|
5675
|
-
"
|
|
5676
|
-
"hardis:org:
|
|
5677
|
-
"org:hardis:
|
|
5678
|
-
"org:
|
|
5679
|
-
"org:
|
|
5680
|
-
"hardis:
|
|
5681
|
-
"
|
|
5682
|
-
"
|
|
5683
|
-
"
|
|
5684
|
-
"hardis:
|
|
5685
|
-
"
|
|
5686
|
-
"
|
|
5687
|
-
"
|
|
5649
|
+
"hardis:org:diagnose:audittrail",
|
|
5650
|
+
"org:hardis:diagnose:audittrail",
|
|
5651
|
+
"org:diagnose:hardis:audittrail",
|
|
5652
|
+
"org:diagnose:audittrail:hardis",
|
|
5653
|
+
"hardis:diagnose:org:audittrail",
|
|
5654
|
+
"diagnose:hardis:org:audittrail",
|
|
5655
|
+
"diagnose:org:hardis:audittrail",
|
|
5656
|
+
"diagnose:org:audittrail:hardis",
|
|
5657
|
+
"hardis:diagnose:audittrail:org",
|
|
5658
|
+
"diagnose:hardis:audittrail:org",
|
|
5659
|
+
"diagnose:audittrail:hardis:org",
|
|
5660
|
+
"diagnose:audittrail:org:hardis",
|
|
5661
|
+
"hardis:org:audittrail:diagnose",
|
|
5662
|
+
"org:hardis:audittrail:diagnose",
|
|
5663
|
+
"org:audittrail:hardis:diagnose",
|
|
5664
|
+
"org:audittrail:diagnose:hardis",
|
|
5665
|
+
"hardis:audittrail:org:diagnose",
|
|
5666
|
+
"audittrail:hardis:org:diagnose",
|
|
5667
|
+
"audittrail:org:hardis:diagnose",
|
|
5668
|
+
"audittrail:org:diagnose:hardis",
|
|
5669
|
+
"hardis:audittrail:diagnose:org",
|
|
5670
|
+
"audittrail:hardis:diagnose:org",
|
|
5671
|
+
"audittrail:diagnose:hardis:org",
|
|
5672
|
+
"audittrail:diagnose:org:hardis"
|
|
5688
5673
|
]
|
|
5689
5674
|
},
|
|
5690
|
-
"hardis:org:
|
|
5675
|
+
"hardis:org:diagnose:instanceupgrade": {
|
|
5691
5676
|
"aliases": [],
|
|
5692
5677
|
"args": {},
|
|
5693
|
-
"description": "\
|
|
5678
|
+
"description": "\n## Command Behavior\n\n**Retrieves and displays the scheduled upgrade date for a Salesforce org's instance.**\n\nThis command provides crucial information about when your Salesforce instance will be upgraded to the next major release (Spring, Summer, or Winter). This is vital for release planning, testing, and ensuring compatibility with upcoming Salesforce features.\n\nKey functionalities:\n\n- **Instance Identification:** Determines the Salesforce instance name of your target org.\n- **Upgrade Date Retrieval:** Fetches the planned start time of the next major core service upgrade for that instance from the Salesforce Status API.\n- **Days Until Upgrade:** Calculates and displays the number of days remaining until the next major upgrade.\n- **Severity-Based Logging:** Adjusts the log severity (info, warning) based on the proximity of the upgrade date, providing a visual cue for urgency.\n- **Notifications:** Sends notifications to configured channels (e.g., Slack, MS Teams, Grafana) with the upgrade information, making it suitable for automated monitoring.\n\n<details markdown=\"1\">\n<summary>Technical explanations</summary>\n\nThe command's technical implementation involves:\n\n- **Salesforce SOQL Query:** It first queries the `Organization` object in Salesforce to get the `InstanceName` of the target org.\n- **Salesforce Status API Integration:** It makes an HTTP GET request to the Salesforce Status API (`https://api.status.salesforce.com/v1/instances/{instanceName}/status`) to retrieve detailed information about the instance, including scheduled maintenances.\n- **Data Parsing:** It parses the JSON response from the Status API to extract the relevant major release upgrade information.\n- **Date Calculation:** Uses the `moment` library to calculate the difference in days between the current date and the planned upgrade date.\n- **Notification Integration:** It integrates with the `NotifProvider` to send notifications, including the instance name, upgrade date, and days remaining, along with relevant metrics for monitoring dashboards.\n- **User Feedback:** Provides clear messages to the user about the upgrade status and proximity.\n</details>\n",
|
|
5694
5679
|
"examples": [
|
|
5695
|
-
"$ sf hardis:org:
|
|
5680
|
+
"$ sf hardis:org:diagnose:instanceupgrade"
|
|
5696
5681
|
],
|
|
5697
5682
|
"flags": {
|
|
5698
5683
|
"json": {
|
|
@@ -5710,21 +5695,6 @@
|
|
|
5710
5695
|
"multiple": false,
|
|
5711
5696
|
"type": "option"
|
|
5712
5697
|
},
|
|
5713
|
-
"path": {
|
|
5714
|
-
"char": "p",
|
|
5715
|
-
"description": "Path to the file export project",
|
|
5716
|
-
"name": "path",
|
|
5717
|
-
"hasDynamicHelp": false,
|
|
5718
|
-
"multiple": false,
|
|
5719
|
-
"type": "option"
|
|
5720
|
-
},
|
|
5721
|
-
"overwrite": {
|
|
5722
|
-
"char": "f",
|
|
5723
|
-
"description": "Override existing files (doubles the number of API calls)",
|
|
5724
|
-
"name": "overwrite",
|
|
5725
|
-
"allowNo": false,
|
|
5726
|
-
"type": "boolean"
|
|
5727
|
-
},
|
|
5728
5698
|
"debug": {
|
|
5729
5699
|
"char": "d",
|
|
5730
5700
|
"description": "Activate debug mode (more logs)",
|
|
@@ -5763,13 +5733,13 @@
|
|
|
5763
5733
|
},
|
|
5764
5734
|
"hasDynamicHelp": true,
|
|
5765
5735
|
"hiddenAliases": [],
|
|
5766
|
-
"id": "hardis:org:
|
|
5736
|
+
"id": "hardis:org:diagnose:instanceupgrade",
|
|
5767
5737
|
"pluginAlias": "sfdx-hardis",
|
|
5768
5738
|
"pluginName": "sfdx-hardis",
|
|
5769
5739
|
"pluginType": "core",
|
|
5770
5740
|
"strict": true,
|
|
5771
5741
|
"enableJsonFlag": true,
|
|
5772
|
-
"title": "
|
|
5742
|
+
"title": "Get Instance Upgrade date",
|
|
5773
5743
|
"requiresProject": false,
|
|
5774
5744
|
"isESM": true,
|
|
5775
5745
|
"relativePath": [
|
|
@@ -5777,247 +5747,8 @@
|
|
|
5777
5747
|
"commands",
|
|
5778
5748
|
"hardis",
|
|
5779
5749
|
"org",
|
|
5780
|
-
"
|
|
5781
|
-
"
|
|
5782
|
-
],
|
|
5783
|
-
"aliasPermutations": [],
|
|
5784
|
-
"permutations": [
|
|
5785
|
-
"hardis:org:files:import",
|
|
5786
|
-
"org:hardis:files:import",
|
|
5787
|
-
"org:files:hardis:import",
|
|
5788
|
-
"org:files:import:hardis",
|
|
5789
|
-
"hardis:files:org:import",
|
|
5790
|
-
"files:hardis:org:import",
|
|
5791
|
-
"files:org:hardis:import",
|
|
5792
|
-
"files:org:import:hardis",
|
|
5793
|
-
"hardis:files:import:org",
|
|
5794
|
-
"files:hardis:import:org",
|
|
5795
|
-
"files:import:hardis:org",
|
|
5796
|
-
"files:import:org:hardis",
|
|
5797
|
-
"hardis:org:import:files",
|
|
5798
|
-
"org:hardis:import:files",
|
|
5799
|
-
"org:import:hardis:files",
|
|
5800
|
-
"org:import:files:hardis",
|
|
5801
|
-
"hardis:import:org:files",
|
|
5802
|
-
"import:hardis:org:files",
|
|
5803
|
-
"import:org:hardis:files",
|
|
5804
|
-
"import:org:files:hardis",
|
|
5805
|
-
"hardis:import:files:org",
|
|
5806
|
-
"import:hardis:files:org",
|
|
5807
|
-
"import:files:hardis:org",
|
|
5808
|
-
"import:files:org:hardis"
|
|
5809
|
-
]
|
|
5810
|
-
},
|
|
5811
|
-
"hardis:org:diagnose:audittrail": {
|
|
5812
|
-
"aliases": [],
|
|
5813
|
-
"args": {},
|
|
5814
|
-
"description": "Export Audit trail into a CSV file with selected criteria, and highlight suspect actions\n\nAlso detects updates of Custom Settings values (disable by defining `SKIP_AUDIT_TRAIL_CUSTOM_SETTINGS=true`)\n\nRegular setup actions performed in major orgs are filtered.\n\n- \"\"\n - createScratchOrg\n - changedsenderemail\n - deleteScratchOrg\n - loginasgrantedtopartnerbt\n- Certificate and Key Management\n - insertCertificate\n- Custom App Licenses\n - addeduserpackagelicense\n - granteduserpackagelicense\n - revokeduserpackagelicense\n- Customer Portal\n - createdcustomersuccessuser\n - CSPUserDisabled\n- Currency\n - updateddatedexchrate\n- Data Management\n - queueMembership\n- Email Administration\n - dkimRotationPreparationSuccessful\n - dkimRotationSuccessful\n- External Objects\n - xdsEncryptedFieldChange\n- Groups\n - groupMembership\n- Holidays\n - holiday_insert\n- Inbox mobile and legacy desktop apps\n - enableSIQUserNonEAC\n - siqUserAcceptedTOS\n- Manage Users\n - activateduser\n - createduser\n - changedcommunitynickname\n - changedemail\n - changedfederationid\n - changedpassword\n - changedinteractionuseroffon\n - changedinteractionuseronoff\n - changedmarketinguseroffon\n - changedmarketinguseronoff\n - changedofflineuseroffon\n - changedprofileforuserstdtostd\n - changedprofileforuser\n - changedprofileforusercusttostd\n - changedprofileforuserstdtocust\n - changedroleforusertonone\n - changedroleforuser\n - changedroleforuserfromnone\n - changedUserAdminVerifiedStatusVerified\n - changedUserEmailVerifiedStatusUnverified\n - changedUserEmailVerifiedStatusVerified\n - changedknowledgeuseroffon\n - changedsfcontentuseroffon\n - changedsupportuseroffon\n - changedusername\n - changedUserPhoneNumber\n - changedUserPhoneVerifiedStatusUnverified\n - changedUserPhoneVerifiedStatusVerified\n - deactivateduser\n - deleteAuthenticatorPairing\n - deleteTwoFactorInfo2\n - deleteTwoFactorTempCode\n - frozeuser\n - insertAuthenticatorPairing\n - insertTwoFactorInfo2\n - insertTwoFactorTempCode\n - lightningloginenroll\n - PermSetAssign\n - PermSetGroupAssign\n - PermSetGroupUnassign\n - PermSetLicenseAssign\n - PermSetUnassign\n - PermSetLicenseUnassign\n - registeredUserPhoneNumber\n - resetpassword\n - suNetworkAdminLogin\n - suNetworkAdminLogout\n - suOrgAdminLogin\n - suOrgAdminLogout\n - unfrozeuser\n - useremailchangesent\n- Mobile Administration\n - assigneduserstomobileconfig\n- Reporting Snapshots\n - createdReportJob\n - deletedReportJob\n- Sandboxes\n - DeleteSandbox\n\nBy default, deployment user defined in .sfdx-hardis.yml targetUsername property will be excluded.\n\nYou can define additional users to exclude in .sfdx-hardis.yml **monitoringExcludeUsernames** property.\n\nYou can also add more sections / actions considered as not suspect using property **monitoringAllowedSectionsActions**\n\nExample:\n\n```yaml\nmonitoringExcludeUsernames:\n - deploymentuser@cloudity.com\n - marketingcloud@cloudity.com\n - integration-user@cloudity.com\n\nmonitoringAllowedSectionsActions:\n \"Some section\": [] // Will ignore all actions from such section\n \"Some other section\": [\"actionType1\",\"actionType2\",\"actionType3\"] // Will ignore only those 3 actions from section \"Some other section\". Other actions in the same section will be considered as suspect.\n```\n\n## Excel output example\n\n\n\n## Local output example\n\n\n\nThis command is part of [sfdx-hardis Monitoring](https://sfdx-hardis.cloudity.com/salesforce-monitoring-suspect-audit-trail/) and can output Grafana, Slack and MsTeams Notifications.\n",
|
|
5815
|
-
"examples": [
|
|
5816
|
-
"$ sf hardis:org:diagnose:audittrail",
|
|
5817
|
-
"$ sf hardis:org:diagnose:audittrail --excludeusers baptiste@titi.com",
|
|
5818
|
-
"$ sf hardis:org:diagnose:audittrail --excludeusers baptiste@titi.com,bertrand@titi.com",
|
|
5819
|
-
"$ sf hardis:org:diagnose:audittrail --lastndays 5"
|
|
5820
|
-
],
|
|
5821
|
-
"flags": {
|
|
5822
|
-
"json": {
|
|
5823
|
-
"description": "Format output as json.",
|
|
5824
|
-
"helpGroup": "GLOBAL",
|
|
5825
|
-
"name": "json",
|
|
5826
|
-
"allowNo": false,
|
|
5827
|
-
"type": "boolean"
|
|
5828
|
-
},
|
|
5829
|
-
"flags-dir": {
|
|
5830
|
-
"helpGroup": "GLOBAL",
|
|
5831
|
-
"name": "flags-dir",
|
|
5832
|
-
"summary": "Import flag values from a directory.",
|
|
5833
|
-
"hasDynamicHelp": false,
|
|
5834
|
-
"multiple": false,
|
|
5835
|
-
"type": "option"
|
|
5836
|
-
},
|
|
5837
|
-
"excludeusers": {
|
|
5838
|
-
"char": "e",
|
|
5839
|
-
"description": "Comma-separated list of usernames to exclude",
|
|
5840
|
-
"name": "excludeusers",
|
|
5841
|
-
"hasDynamicHelp": false,
|
|
5842
|
-
"multiple": false,
|
|
5843
|
-
"type": "option"
|
|
5844
|
-
},
|
|
5845
|
-
"lastndays": {
|
|
5846
|
-
"char": "t",
|
|
5847
|
-
"description": "Number of days to extract from today (included)",
|
|
5848
|
-
"name": "lastndays",
|
|
5849
|
-
"hasDynamicHelp": false,
|
|
5850
|
-
"multiple": false,
|
|
5851
|
-
"type": "option"
|
|
5852
|
-
},
|
|
5853
|
-
"outputfile": {
|
|
5854
|
-
"char": "f",
|
|
5855
|
-
"description": "Force the path and name of output report file. Must end with .csv",
|
|
5856
|
-
"name": "outputfile",
|
|
5857
|
-
"hasDynamicHelp": false,
|
|
5858
|
-
"multiple": false,
|
|
5859
|
-
"type": "option"
|
|
5860
|
-
},
|
|
5861
|
-
"debug": {
|
|
5862
|
-
"char": "d",
|
|
5863
|
-
"description": "Activate debug mode (more logs)",
|
|
5864
|
-
"name": "debug",
|
|
5865
|
-
"allowNo": false,
|
|
5866
|
-
"type": "boolean"
|
|
5867
|
-
},
|
|
5868
|
-
"websocket": {
|
|
5869
|
-
"description": "Websocket host:port for VsCode SFDX Hardis UI integration",
|
|
5870
|
-
"name": "websocket",
|
|
5871
|
-
"hasDynamicHelp": false,
|
|
5872
|
-
"multiple": false,
|
|
5873
|
-
"type": "option"
|
|
5874
|
-
},
|
|
5875
|
-
"skipauth": {
|
|
5876
|
-
"description": "Skip authentication check when a default username is required",
|
|
5877
|
-
"name": "skipauth",
|
|
5878
|
-
"allowNo": false,
|
|
5879
|
-
"type": "boolean"
|
|
5880
|
-
},
|
|
5881
|
-
"target-org": {
|
|
5882
|
-
"aliases": [
|
|
5883
|
-
"targetusername",
|
|
5884
|
-
"u"
|
|
5885
|
-
],
|
|
5886
|
-
"char": "o",
|
|
5887
|
-
"deprecateAliases": true,
|
|
5888
|
-
"name": "target-org",
|
|
5889
|
-
"noCacheDefault": true,
|
|
5890
|
-
"required": true,
|
|
5891
|
-
"summary": "Username or alias of the target org. Not required if the `target-org` configuration variable is already set.",
|
|
5892
|
-
"hasDynamicHelp": true,
|
|
5893
|
-
"multiple": false,
|
|
5894
|
-
"type": "option"
|
|
5895
|
-
}
|
|
5896
|
-
},
|
|
5897
|
-
"hasDynamicHelp": true,
|
|
5898
|
-
"hiddenAliases": [],
|
|
5899
|
-
"id": "hardis:org:diagnose:audittrail",
|
|
5900
|
-
"pluginAlias": "sfdx-hardis",
|
|
5901
|
-
"pluginName": "sfdx-hardis",
|
|
5902
|
-
"pluginType": "core",
|
|
5903
|
-
"strict": true,
|
|
5904
|
-
"enableJsonFlag": true,
|
|
5905
|
-
"title": "Diagnose content of Setup Audit Trail",
|
|
5906
|
-
"requiresProject": false,
|
|
5907
|
-
"isESM": true,
|
|
5908
|
-
"relativePath": [
|
|
5909
|
-
"lib",
|
|
5910
|
-
"commands",
|
|
5911
|
-
"hardis",
|
|
5912
|
-
"org",
|
|
5913
|
-
"diagnose",
|
|
5914
|
-
"audittrail.js"
|
|
5915
|
-
],
|
|
5916
|
-
"aliasPermutations": [],
|
|
5917
|
-
"permutations": [
|
|
5918
|
-
"hardis:org:diagnose:audittrail",
|
|
5919
|
-
"org:hardis:diagnose:audittrail",
|
|
5920
|
-
"org:diagnose:hardis:audittrail",
|
|
5921
|
-
"org:diagnose:audittrail:hardis",
|
|
5922
|
-
"hardis:diagnose:org:audittrail",
|
|
5923
|
-
"diagnose:hardis:org:audittrail",
|
|
5924
|
-
"diagnose:org:hardis:audittrail",
|
|
5925
|
-
"diagnose:org:audittrail:hardis",
|
|
5926
|
-
"hardis:diagnose:audittrail:org",
|
|
5927
|
-
"diagnose:hardis:audittrail:org",
|
|
5928
|
-
"diagnose:audittrail:hardis:org",
|
|
5929
|
-
"diagnose:audittrail:org:hardis",
|
|
5930
|
-
"hardis:org:audittrail:diagnose",
|
|
5931
|
-
"org:hardis:audittrail:diagnose",
|
|
5932
|
-
"org:audittrail:hardis:diagnose",
|
|
5933
|
-
"org:audittrail:diagnose:hardis",
|
|
5934
|
-
"hardis:audittrail:org:diagnose",
|
|
5935
|
-
"audittrail:hardis:org:diagnose",
|
|
5936
|
-
"audittrail:org:hardis:diagnose",
|
|
5937
|
-
"audittrail:org:diagnose:hardis",
|
|
5938
|
-
"hardis:audittrail:diagnose:org",
|
|
5939
|
-
"audittrail:hardis:diagnose:org",
|
|
5940
|
-
"audittrail:diagnose:hardis:org",
|
|
5941
|
-
"audittrail:diagnose:org:hardis"
|
|
5942
|
-
]
|
|
5943
|
-
},
|
|
5944
|
-
"hardis:org:diagnose:instanceupgrade": {
|
|
5945
|
-
"aliases": [],
|
|
5946
|
-
"args": {},
|
|
5947
|
-
"description": "\n## Command Behavior\n\n**Retrieves and displays the scheduled upgrade date for a Salesforce org's instance.**\n\nThis command provides crucial information about when your Salesforce instance will be upgraded to the next major release (Spring, Summer, or Winter). This is vital for release planning, testing, and ensuring compatibility with upcoming Salesforce features.\n\nKey functionalities:\n\n- **Instance Identification:** Determines the Salesforce instance name of your target org.\n- **Upgrade Date Retrieval:** Fetches the planned start time of the next major core service upgrade for that instance from the Salesforce Status API.\n- **Days Until Upgrade:** Calculates and displays the number of days remaining until the next major upgrade.\n- **Severity-Based Logging:** Adjusts the log severity (info, warning) based on the proximity of the upgrade date, providing a visual cue for urgency.\n- **Notifications:** Sends notifications to configured channels (e.g., Slack, MS Teams, Grafana) with the upgrade information, making it suitable for automated monitoring.\n\n<details markdown=\"1\">\n<summary>Technical explanations</summary>\n\nThe command's technical implementation involves:\n\n- **Salesforce SOQL Query:** It first queries the `Organization` object in Salesforce to get the `InstanceName` of the target org.\n- **Salesforce Status API Integration:** It makes an HTTP GET request to the Salesforce Status API (`https://api.status.salesforce.com/v1/instances/{instanceName}/status`) to retrieve detailed information about the instance, including scheduled maintenances.\n- **Data Parsing:** It parses the JSON response from the Status API to extract the relevant major release upgrade information.\n- **Date Calculation:** Uses the `moment` library to calculate the difference in days between the current date and the planned upgrade date.\n- **Notification Integration:** It integrates with the `NotifProvider` to send notifications, including the instance name, upgrade date, and days remaining, along with relevant metrics for monitoring dashboards.\n- **User Feedback:** Provides clear messages to the user about the upgrade status and proximity.\n</details>\n",
|
|
5948
|
-
"examples": [
|
|
5949
|
-
"$ sf hardis:org:diagnose:instanceupgrade"
|
|
5950
|
-
],
|
|
5951
|
-
"flags": {
|
|
5952
|
-
"json": {
|
|
5953
|
-
"description": "Format output as json.",
|
|
5954
|
-
"helpGroup": "GLOBAL",
|
|
5955
|
-
"name": "json",
|
|
5956
|
-
"allowNo": false,
|
|
5957
|
-
"type": "boolean"
|
|
5958
|
-
},
|
|
5959
|
-
"flags-dir": {
|
|
5960
|
-
"helpGroup": "GLOBAL",
|
|
5961
|
-
"name": "flags-dir",
|
|
5962
|
-
"summary": "Import flag values from a directory.",
|
|
5963
|
-
"hasDynamicHelp": false,
|
|
5964
|
-
"multiple": false,
|
|
5965
|
-
"type": "option"
|
|
5966
|
-
},
|
|
5967
|
-
"debug": {
|
|
5968
|
-
"char": "d",
|
|
5969
|
-
"description": "Activate debug mode (more logs)",
|
|
5970
|
-
"name": "debug",
|
|
5971
|
-
"allowNo": false,
|
|
5972
|
-
"type": "boolean"
|
|
5973
|
-
},
|
|
5974
|
-
"websocket": {
|
|
5975
|
-
"description": "Websocket host:port for VsCode SFDX Hardis UI integration",
|
|
5976
|
-
"name": "websocket",
|
|
5977
|
-
"hasDynamicHelp": false,
|
|
5978
|
-
"multiple": false,
|
|
5979
|
-
"type": "option"
|
|
5980
|
-
},
|
|
5981
|
-
"skipauth": {
|
|
5982
|
-
"description": "Skip authentication check when a default username is required",
|
|
5983
|
-
"name": "skipauth",
|
|
5984
|
-
"allowNo": false,
|
|
5985
|
-
"type": "boolean"
|
|
5986
|
-
},
|
|
5987
|
-
"target-org": {
|
|
5988
|
-
"aliases": [
|
|
5989
|
-
"targetusername",
|
|
5990
|
-
"u"
|
|
5991
|
-
],
|
|
5992
|
-
"char": "o",
|
|
5993
|
-
"deprecateAliases": true,
|
|
5994
|
-
"name": "target-org",
|
|
5995
|
-
"noCacheDefault": true,
|
|
5996
|
-
"required": true,
|
|
5997
|
-
"summary": "Username or alias of the target org. Not required if the `target-org` configuration variable is already set.",
|
|
5998
|
-
"hasDynamicHelp": true,
|
|
5999
|
-
"multiple": false,
|
|
6000
|
-
"type": "option"
|
|
6001
|
-
}
|
|
6002
|
-
},
|
|
6003
|
-
"hasDynamicHelp": true,
|
|
6004
|
-
"hiddenAliases": [],
|
|
6005
|
-
"id": "hardis:org:diagnose:instanceupgrade",
|
|
6006
|
-
"pluginAlias": "sfdx-hardis",
|
|
6007
|
-
"pluginName": "sfdx-hardis",
|
|
6008
|
-
"pluginType": "core",
|
|
6009
|
-
"strict": true,
|
|
6010
|
-
"enableJsonFlag": true,
|
|
6011
|
-
"title": "Get Instance Upgrade date",
|
|
6012
|
-
"requiresProject": false,
|
|
6013
|
-
"isESM": true,
|
|
6014
|
-
"relativePath": [
|
|
6015
|
-
"lib",
|
|
6016
|
-
"commands",
|
|
6017
|
-
"hardis",
|
|
6018
|
-
"org",
|
|
6019
|
-
"diagnose",
|
|
6020
|
-
"instanceupgrade.js"
|
|
5750
|
+
"diagnose",
|
|
5751
|
+
"instanceupgrade.js"
|
|
6021
5752
|
],
|
|
6022
5753
|
"aliasPermutations": [],
|
|
6023
5754
|
"permutations": [
|
|
@@ -7206,13 +6937,12 @@
|
|
|
7206
6937
|
"unusedusers:diagnose:org:hardis"
|
|
7207
6938
|
]
|
|
7208
6939
|
},
|
|
7209
|
-
"hardis:org:
|
|
6940
|
+
"hardis:org:files:export": {
|
|
7210
6941
|
"aliases": [],
|
|
7211
6942
|
"args": {},
|
|
7212
|
-
"description": "
|
|
6943
|
+
"description": "\n## Command Behavior\n\n**Exports file attachments (ContentVersion, Attachment) from a Salesforce org based on a predefined configuration.**\n\nThis command enables the mass download of files associated with Salesforce records, providing a robust solution for backing up files, migrating them to other systems, or integrating them with external document management solutions.\n\nKey functionalities:\n\n- **Configuration-Driven Export:** Relies on an `export.json` file within a designated file export project to define the export criteria, including the SOQL query for parent records, file types to export, output naming conventions, and file size filtering.\n- **File Size Filtering:** Supports minimum file size filtering via the `fileSizeMin` configuration parameter (in KB). Files smaller than the specified size will be skipped during export.\n- **File Validation:** After downloading each file, validates the integrity by:\n - **Checksum Validation:** For ContentVersion files, compares MD5 checksum with Salesforce's stored checksum\n - **Size Validation:** For both ContentVersion and Attachment files, verifies actual file size matches expected size\n - **Status Tracking:** Files are categorized with specific statuses: `success` (valid files), `failed` (download errors), `skipped` (filtered files), `invalid` (downloaded but failed validation)\n - All validation results are logged in the CSV export log for audit purposes\n- **Resume/Restart Capability:** \n - **Resume Mode:** When `--resume` flag is used (default in CI environments), checks existing downloaded files for validity. Valid files are skipped, invalid files are re-downloaded.\n - **Restart Mode:** When resume is disabled, clears the output folder and starts a fresh export.\n - **Interactive Mode:** When existing files are found and `--resume` is not explicitly specified (non-CI environments), prompts the user to choose between resume or restart.\n- **Interactive Project Selection:** If the file export project path is not provided via the `--path` flag, it interactively prompts the user to select one.\n- **Configurable Export Options:** Allows overriding default export settings such as `chunksize` (number of records processed in a batch), `polltimeout` (timeout for Bulk API calls), and `startchunknumber` (to resume a failed export).\n- **Support for ContentVersion and Attachment:** Handles both modern Salesforce Files (ContentVersion) and older Attachments.\n\nSee this article for a practical example:\n\n[](https://nicolas.vuillamy.fr/how-to-mass-download-notes-and-attachments-files-from-a-salesforce-org-83a028824afd)\n\n<details markdown=\"1\">\n<summary>Technical explanations</summary>\n\nThe command's technical implementation involves:\n\n- **FilesExporter Class:** The core logic is encapsulated within the `FilesExporter` class, which orchestrates the entire export process.\n- **SOQL Queries (Bulk API):** It uses Salesforce Bulk API queries to efficiently retrieve large volumes of parent record IDs and file metadata, including checksums and file sizes.\n- **File Download:** Downloads the actual file content from Salesforce.\n- **File Validation:** After each successful download, validates file integrity by comparing checksums (ContentVersion) and file sizes (both ContentVersion and Attachment) against Salesforce metadata.\n- **Resume Logic:** In resume mode, checks for existing files before downloading, validates their integrity, and only re-downloads invalid or missing files. This enables efficient recovery from interrupted exports.\n- **File System Operations:** Writes the downloaded files to the local file system, organizing them into folders based on the configured naming conventions.\n- **Configuration Loading:** Reads the `export.json` file to get the export configuration. It also allows for interactive overriding of these settings.\n- **Interactive Prompts:** Uses `selectFilesWorkspace` to allow the user to choose a file export project, `promptFilesExportConfiguration` for customizing export options, and prompts for resume/restart choice when existing files are found.\n- **Error Handling:** Includes mechanisms to handle potential errors during the export process, such as network issues, API limits, and file validation failures. Each file is assigned a specific status (`success`, `failed`, `skipped`, `invalid`) for comprehensive tracking and troubleshooting.\n</details>\n",
|
|
7213
6944
|
"examples": [
|
|
7214
|
-
"$ sf hardis:org:
|
|
7215
|
-
"$ sf hardis:org:fix:listviewmine --listviews Opportunity:MySubscriptions,Account:MyActivePartners"
|
|
6945
|
+
"$ sf hardis:org:files:export"
|
|
7216
6946
|
],
|
|
7217
6947
|
"flags": {
|
|
7218
6948
|
"json": {
|
|
@@ -7230,33 +6960,303 @@
|
|
|
7230
6960
|
"multiple": false,
|
|
7231
6961
|
"type": "option"
|
|
7232
6962
|
},
|
|
7233
|
-
"
|
|
7234
|
-
"char": "
|
|
7235
|
-
"description": "
|
|
7236
|
-
"name": "
|
|
6963
|
+
"path": {
|
|
6964
|
+
"char": "p",
|
|
6965
|
+
"description": "Path to the file export project",
|
|
6966
|
+
"name": "path",
|
|
7237
6967
|
"hasDynamicHelp": false,
|
|
7238
6968
|
"multiple": false,
|
|
7239
6969
|
"type": "option"
|
|
7240
6970
|
},
|
|
7241
|
-
"
|
|
7242
|
-
"char": "
|
|
7243
|
-
"description": "
|
|
7244
|
-
"name": "
|
|
7245
|
-
"
|
|
7246
|
-
"type": "boolean"
|
|
7247
|
-
},
|
|
7248
|
-
"websocket": {
|
|
7249
|
-
"description": "Websocket host:port for VsCode SFDX Hardis UI integration",
|
|
7250
|
-
"name": "websocket",
|
|
6971
|
+
"chunksize": {
|
|
6972
|
+
"char": "c",
|
|
6973
|
+
"description": "Number of records to add in a chunk before it is processed",
|
|
6974
|
+
"name": "chunksize",
|
|
6975
|
+
"default": 1000,
|
|
7251
6976
|
"hasDynamicHelp": false,
|
|
7252
6977
|
"multiple": false,
|
|
7253
6978
|
"type": "option"
|
|
7254
6979
|
},
|
|
7255
|
-
"
|
|
7256
|
-
"
|
|
7257
|
-
"
|
|
7258
|
-
"
|
|
7259
|
-
"
|
|
6980
|
+
"polltimeout": {
|
|
6981
|
+
"char": "t",
|
|
6982
|
+
"description": "Timeout in MS for Bulk API calls",
|
|
6983
|
+
"name": "polltimeout",
|
|
6984
|
+
"default": 300000,
|
|
6985
|
+
"hasDynamicHelp": false,
|
|
6986
|
+
"multiple": false,
|
|
6987
|
+
"type": "option"
|
|
6988
|
+
},
|
|
6989
|
+
"startchunknumber": {
|
|
6990
|
+
"char": "s",
|
|
6991
|
+
"description": "Chunk number to start from",
|
|
6992
|
+
"name": "startchunknumber",
|
|
6993
|
+
"default": 0,
|
|
6994
|
+
"hasDynamicHelp": false,
|
|
6995
|
+
"multiple": false,
|
|
6996
|
+
"type": "option"
|
|
6997
|
+
},
|
|
6998
|
+
"resume": {
|
|
6999
|
+
"char": "r",
|
|
7000
|
+
"description": "Resume previous export by checking existing files (default in CI)",
|
|
7001
|
+
"name": "resume",
|
|
7002
|
+
"allowNo": false,
|
|
7003
|
+
"type": "boolean"
|
|
7004
|
+
},
|
|
7005
|
+
"debug": {
|
|
7006
|
+
"char": "d",
|
|
7007
|
+
"description": "Activate debug mode (more logs)",
|
|
7008
|
+
"name": "debug",
|
|
7009
|
+
"allowNo": false,
|
|
7010
|
+
"type": "boolean"
|
|
7011
|
+
},
|
|
7012
|
+
"websocket": {
|
|
7013
|
+
"description": "Websocket host:port for VsCode SFDX Hardis UI integration",
|
|
7014
|
+
"name": "websocket",
|
|
7015
|
+
"hasDynamicHelp": false,
|
|
7016
|
+
"multiple": false,
|
|
7017
|
+
"type": "option"
|
|
7018
|
+
},
|
|
7019
|
+
"skipauth": {
|
|
7020
|
+
"description": "Skip authentication check when a default username is required",
|
|
7021
|
+
"name": "skipauth",
|
|
7022
|
+
"allowNo": false,
|
|
7023
|
+
"type": "boolean"
|
|
7024
|
+
},
|
|
7025
|
+
"target-org": {
|
|
7026
|
+
"aliases": [
|
|
7027
|
+
"targetusername",
|
|
7028
|
+
"u"
|
|
7029
|
+
],
|
|
7030
|
+
"char": "o",
|
|
7031
|
+
"deprecateAliases": true,
|
|
7032
|
+
"name": "target-org",
|
|
7033
|
+
"noCacheDefault": true,
|
|
7034
|
+
"required": true,
|
|
7035
|
+
"summary": "Username or alias of the target org. Not required if the `target-org` configuration variable is already set.",
|
|
7036
|
+
"hasDynamicHelp": true,
|
|
7037
|
+
"multiple": false,
|
|
7038
|
+
"type": "option"
|
|
7039
|
+
}
|
|
7040
|
+
},
|
|
7041
|
+
"hasDynamicHelp": true,
|
|
7042
|
+
"hiddenAliases": [],
|
|
7043
|
+
"id": "hardis:org:files:export",
|
|
7044
|
+
"pluginAlias": "sfdx-hardis",
|
|
7045
|
+
"pluginName": "sfdx-hardis",
|
|
7046
|
+
"pluginType": "core",
|
|
7047
|
+
"strict": true,
|
|
7048
|
+
"enableJsonFlag": true,
|
|
7049
|
+
"title": "Export files",
|
|
7050
|
+
"requiresProject": false,
|
|
7051
|
+
"isESM": true,
|
|
7052
|
+
"relativePath": [
|
|
7053
|
+
"lib",
|
|
7054
|
+
"commands",
|
|
7055
|
+
"hardis",
|
|
7056
|
+
"org",
|
|
7057
|
+
"files",
|
|
7058
|
+
"export.js"
|
|
7059
|
+
],
|
|
7060
|
+
"aliasPermutations": [],
|
|
7061
|
+
"permutations": [
|
|
7062
|
+
"hardis:org:files:export",
|
|
7063
|
+
"org:hardis:files:export",
|
|
7064
|
+
"org:files:hardis:export",
|
|
7065
|
+
"org:files:export:hardis",
|
|
7066
|
+
"hardis:files:org:export",
|
|
7067
|
+
"files:hardis:org:export",
|
|
7068
|
+
"files:org:hardis:export",
|
|
7069
|
+
"files:org:export:hardis",
|
|
7070
|
+
"hardis:files:export:org",
|
|
7071
|
+
"files:hardis:export:org",
|
|
7072
|
+
"files:export:hardis:org",
|
|
7073
|
+
"files:export:org:hardis",
|
|
7074
|
+
"hardis:org:export:files",
|
|
7075
|
+
"org:hardis:export:files",
|
|
7076
|
+
"org:export:hardis:files",
|
|
7077
|
+
"org:export:files:hardis",
|
|
7078
|
+
"hardis:export:org:files",
|
|
7079
|
+
"export:hardis:org:files",
|
|
7080
|
+
"export:org:hardis:files",
|
|
7081
|
+
"export:org:files:hardis",
|
|
7082
|
+
"hardis:export:files:org",
|
|
7083
|
+
"export:hardis:files:org",
|
|
7084
|
+
"export:files:hardis:org",
|
|
7085
|
+
"export:files:org:hardis"
|
|
7086
|
+
]
|
|
7087
|
+
},
|
|
7088
|
+
"hardis:org:files:import": {
|
|
7089
|
+
"aliases": [],
|
|
7090
|
+
"args": {},
|
|
7091
|
+
"description": "\nThis command facilitates the mass upload of files into Salesforce, allowing you to populate records with associated documents, images, or other file types. It's a crucial tool for data migration, content seeding, or synchronizing external file repositories with Salesforce.\n\nKey functionalities:\n\n- **Configuration-Driven Import:** Relies on an `export.json` file within a designated file export project (created using `sf hardis:org:configure:files`) to determine which files to import and how they should be associated with Salesforce records.\n- **Interactive Project Selection:** If the file import project path is not provided via the `--path` flag, it interactively prompts the user to select one.\n- **Overwrite Option:** The `--overwrite` flag allows you to replace existing files in Salesforce with local versions that have the same name. Be aware that this option doubles the number of API calls used.\n- **Support for ContentVersion and Attachment:** Handles both modern Salesforce Files (ContentVersion) and older Attachments.\n\nSee this article for how to export files, which is often a prerequisite for importing:\n\n[](https://nicolas.vuillamy.fr/how-to-mass-download-notes-and-attachments-files-from-a-salesforce-org-83a028824afd)\n\n<details markdown=\"1\">\n<summary>Technical explanations</summary>\n\nThe command's technical implementation involves:\n\n- **FilesImporter Class:** The core logic is encapsulated within the `FilesImporter` class, which orchestrates the entire import process.\n- **File System Scan:** Scans the local file system within the configured project directory to identify files for import.\n- **Salesforce API Interaction:** Uses Salesforce APIs (e.g., ContentVersion, Attachment) to upload files and associate them with records.\n- **Configuration Loading:** Reads the `export.json` file to get the import configuration, including SOQL queries to identify parent records for file association.\n- **Interactive Prompts:** Uses `selectFilesWorkspace` to allow the user to choose a file import project and `prompts` for confirming the overwrite behavior.\n- **Error Handling:** Includes mechanisms to handle potential errors during the import process, such as API limits or file upload failures.\n</details>\n",
|
|
7092
|
+
"examples": [
|
|
7093
|
+
"$ sf hardis:org:files:import"
|
|
7094
|
+
],
|
|
7095
|
+
"flags": {
|
|
7096
|
+
"json": {
|
|
7097
|
+
"description": "Format output as json.",
|
|
7098
|
+
"helpGroup": "GLOBAL",
|
|
7099
|
+
"name": "json",
|
|
7100
|
+
"allowNo": false,
|
|
7101
|
+
"type": "boolean"
|
|
7102
|
+
},
|
|
7103
|
+
"flags-dir": {
|
|
7104
|
+
"helpGroup": "GLOBAL",
|
|
7105
|
+
"name": "flags-dir",
|
|
7106
|
+
"summary": "Import flag values from a directory.",
|
|
7107
|
+
"hasDynamicHelp": false,
|
|
7108
|
+
"multiple": false,
|
|
7109
|
+
"type": "option"
|
|
7110
|
+
},
|
|
7111
|
+
"path": {
|
|
7112
|
+
"char": "p",
|
|
7113
|
+
"description": "Path to the file export project",
|
|
7114
|
+
"name": "path",
|
|
7115
|
+
"hasDynamicHelp": false,
|
|
7116
|
+
"multiple": false,
|
|
7117
|
+
"type": "option"
|
|
7118
|
+
},
|
|
7119
|
+
"overwrite": {
|
|
7120
|
+
"char": "f",
|
|
7121
|
+
"description": "Override existing files (doubles the number of API calls)",
|
|
7122
|
+
"name": "overwrite",
|
|
7123
|
+
"allowNo": false,
|
|
7124
|
+
"type": "boolean"
|
|
7125
|
+
},
|
|
7126
|
+
"debug": {
|
|
7127
|
+
"char": "d",
|
|
7128
|
+
"description": "Activate debug mode (more logs)",
|
|
7129
|
+
"name": "debug",
|
|
7130
|
+
"allowNo": false,
|
|
7131
|
+
"type": "boolean"
|
|
7132
|
+
},
|
|
7133
|
+
"websocket": {
|
|
7134
|
+
"description": "Websocket host:port for VsCode SFDX Hardis UI integration",
|
|
7135
|
+
"name": "websocket",
|
|
7136
|
+
"hasDynamicHelp": false,
|
|
7137
|
+
"multiple": false,
|
|
7138
|
+
"type": "option"
|
|
7139
|
+
},
|
|
7140
|
+
"skipauth": {
|
|
7141
|
+
"description": "Skip authentication check when a default username is required",
|
|
7142
|
+
"name": "skipauth",
|
|
7143
|
+
"allowNo": false,
|
|
7144
|
+
"type": "boolean"
|
|
7145
|
+
},
|
|
7146
|
+
"target-org": {
|
|
7147
|
+
"aliases": [
|
|
7148
|
+
"targetusername",
|
|
7149
|
+
"u"
|
|
7150
|
+
],
|
|
7151
|
+
"char": "o",
|
|
7152
|
+
"deprecateAliases": true,
|
|
7153
|
+
"name": "target-org",
|
|
7154
|
+
"noCacheDefault": true,
|
|
7155
|
+
"required": true,
|
|
7156
|
+
"summary": "Username or alias of the target org. Not required if the `target-org` configuration variable is already set.",
|
|
7157
|
+
"hasDynamicHelp": true,
|
|
7158
|
+
"multiple": false,
|
|
7159
|
+
"type": "option"
|
|
7160
|
+
}
|
|
7161
|
+
},
|
|
7162
|
+
"hasDynamicHelp": true,
|
|
7163
|
+
"hiddenAliases": [],
|
|
7164
|
+
"id": "hardis:org:files:import",
|
|
7165
|
+
"pluginAlias": "sfdx-hardis",
|
|
7166
|
+
"pluginName": "sfdx-hardis",
|
|
7167
|
+
"pluginType": "core",
|
|
7168
|
+
"strict": true,
|
|
7169
|
+
"enableJsonFlag": true,
|
|
7170
|
+
"title": "Import files",
|
|
7171
|
+
"requiresProject": false,
|
|
7172
|
+
"isESM": true,
|
|
7173
|
+
"relativePath": [
|
|
7174
|
+
"lib",
|
|
7175
|
+
"commands",
|
|
7176
|
+
"hardis",
|
|
7177
|
+
"org",
|
|
7178
|
+
"files",
|
|
7179
|
+
"import.js"
|
|
7180
|
+
],
|
|
7181
|
+
"aliasPermutations": [],
|
|
7182
|
+
"permutations": [
|
|
7183
|
+
"hardis:org:files:import",
|
|
7184
|
+
"org:hardis:files:import",
|
|
7185
|
+
"org:files:hardis:import",
|
|
7186
|
+
"org:files:import:hardis",
|
|
7187
|
+
"hardis:files:org:import",
|
|
7188
|
+
"files:hardis:org:import",
|
|
7189
|
+
"files:org:hardis:import",
|
|
7190
|
+
"files:org:import:hardis",
|
|
7191
|
+
"hardis:files:import:org",
|
|
7192
|
+
"files:hardis:import:org",
|
|
7193
|
+
"files:import:hardis:org",
|
|
7194
|
+
"files:import:org:hardis",
|
|
7195
|
+
"hardis:org:import:files",
|
|
7196
|
+
"org:hardis:import:files",
|
|
7197
|
+
"org:import:hardis:files",
|
|
7198
|
+
"org:import:files:hardis",
|
|
7199
|
+
"hardis:import:org:files",
|
|
7200
|
+
"import:hardis:org:files",
|
|
7201
|
+
"import:org:hardis:files",
|
|
7202
|
+
"import:org:files:hardis",
|
|
7203
|
+
"hardis:import:files:org",
|
|
7204
|
+
"import:hardis:files:org",
|
|
7205
|
+
"import:files:hardis:org",
|
|
7206
|
+
"import:files:org:hardis"
|
|
7207
|
+
]
|
|
7208
|
+
},
|
|
7209
|
+
"hardis:org:fix:listviewmine": {
|
|
7210
|
+
"aliases": [],
|
|
7211
|
+
"args": {},
|
|
7212
|
+
"description": "Fix listviews whose scope Mine has been replaced by Everything\n\n[](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",
|
|
7213
|
+
"examples": [
|
|
7214
|
+
"$ sf hardis:org:fix:listviewmine",
|
|
7215
|
+
"$ sf hardis:org:fix:listviewmine --listviews Opportunity:MySubscriptions,Account:MyActivePartners"
|
|
7216
|
+
],
|
|
7217
|
+
"flags": {
|
|
7218
|
+
"json": {
|
|
7219
|
+
"description": "Format output as json.",
|
|
7220
|
+
"helpGroup": "GLOBAL",
|
|
7221
|
+
"name": "json",
|
|
7222
|
+
"allowNo": false,
|
|
7223
|
+
"type": "boolean"
|
|
7224
|
+
},
|
|
7225
|
+
"flags-dir": {
|
|
7226
|
+
"helpGroup": "GLOBAL",
|
|
7227
|
+
"name": "flags-dir",
|
|
7228
|
+
"summary": "Import flag values from a directory.",
|
|
7229
|
+
"hasDynamicHelp": false,
|
|
7230
|
+
"multiple": false,
|
|
7231
|
+
"type": "option"
|
|
7232
|
+
},
|
|
7233
|
+
"listviews": {
|
|
7234
|
+
"char": "l",
|
|
7235
|
+
"description": "Comma-separated list of listviews following format Object:ListViewName\nExample: Contact:MyContacts,Contact:MyActiveContacts,Opportunity:MYClosedOpportunities",
|
|
7236
|
+
"name": "listviews",
|
|
7237
|
+
"hasDynamicHelp": false,
|
|
7238
|
+
"multiple": false,
|
|
7239
|
+
"type": "option"
|
|
7240
|
+
},
|
|
7241
|
+
"debug": {
|
|
7242
|
+
"char": "d",
|
|
7243
|
+
"description": "Activate debug mode (more logs)",
|
|
7244
|
+
"name": "debug",
|
|
7245
|
+
"allowNo": false,
|
|
7246
|
+
"type": "boolean"
|
|
7247
|
+
},
|
|
7248
|
+
"websocket": {
|
|
7249
|
+
"description": "Websocket host:port for VsCode SFDX Hardis UI integration",
|
|
7250
|
+
"name": "websocket",
|
|
7251
|
+
"hasDynamicHelp": false,
|
|
7252
|
+
"multiple": false,
|
|
7253
|
+
"type": "option"
|
|
7254
|
+
},
|
|
7255
|
+
"skipauth": {
|
|
7256
|
+
"description": "Skip authentication check when a default username is required",
|
|
7257
|
+
"name": "skipauth",
|
|
7258
|
+
"allowNo": false,
|
|
7259
|
+
"type": "boolean"
|
|
7260
7260
|
},
|
|
7261
7261
|
"target-org": {
|
|
7262
7262
|
"aliases": [
|
|
@@ -8093,18 +8093,125 @@
|
|
|
8093
8093
|
"allowNo": false,
|
|
8094
8094
|
"type": "boolean"
|
|
8095
8095
|
},
|
|
8096
|
-
"allowpurgefailure": {
|
|
8097
|
-
"char": "f",
|
|
8098
|
-
"description": "Allows purges to fail without exiting with 1. Use --no-allowpurgefailure to disable",
|
|
8099
|
-
"name": "allowpurgefailure",
|
|
8100
|
-
"allowNo": true,
|
|
8101
|
-
"type": "boolean"
|
|
8102
|
-
},
|
|
8103
|
-
"instanceurl": {
|
|
8104
|
-
"char": "r",
|
|
8105
|
-
"description": "URL of org instance",
|
|
8106
|
-
"name": "instanceurl",
|
|
8107
|
-
"default": "https://login.salesforce.com",
|
|
8096
|
+
"allowpurgefailure": {
|
|
8097
|
+
"char": "f",
|
|
8098
|
+
"description": "Allows purges to fail without exiting with 1. Use --no-allowpurgefailure to disable",
|
|
8099
|
+
"name": "allowpurgefailure",
|
|
8100
|
+
"allowNo": true,
|
|
8101
|
+
"type": "boolean"
|
|
8102
|
+
},
|
|
8103
|
+
"instanceurl": {
|
|
8104
|
+
"char": "r",
|
|
8105
|
+
"description": "URL of org instance",
|
|
8106
|
+
"name": "instanceurl",
|
|
8107
|
+
"default": "https://login.salesforce.com",
|
|
8108
|
+
"hasDynamicHelp": false,
|
|
8109
|
+
"multiple": false,
|
|
8110
|
+
"type": "option"
|
|
8111
|
+
},
|
|
8112
|
+
"debug": {
|
|
8113
|
+
"char": "d",
|
|
8114
|
+
"description": "Activate debug mode (more logs)",
|
|
8115
|
+
"name": "debug",
|
|
8116
|
+
"allowNo": false,
|
|
8117
|
+
"type": "boolean"
|
|
8118
|
+
},
|
|
8119
|
+
"websocket": {
|
|
8120
|
+
"description": "Websocket host:port for VsCode SFDX Hardis UI integration",
|
|
8121
|
+
"name": "websocket",
|
|
8122
|
+
"hasDynamicHelp": false,
|
|
8123
|
+
"multiple": false,
|
|
8124
|
+
"type": "option"
|
|
8125
|
+
},
|
|
8126
|
+
"skipauth": {
|
|
8127
|
+
"description": "Skip authentication check when a default username is required",
|
|
8128
|
+
"name": "skipauth",
|
|
8129
|
+
"allowNo": false,
|
|
8130
|
+
"type": "boolean"
|
|
8131
|
+
},
|
|
8132
|
+
"target-org": {
|
|
8133
|
+
"aliases": [
|
|
8134
|
+
"targetusername",
|
|
8135
|
+
"u"
|
|
8136
|
+
],
|
|
8137
|
+
"char": "o",
|
|
8138
|
+
"deprecateAliases": true,
|
|
8139
|
+
"name": "target-org",
|
|
8140
|
+
"noCacheDefault": true,
|
|
8141
|
+
"required": true,
|
|
8142
|
+
"summary": "Username or alias of the target org. Not required if the `target-org` configuration variable is already set.",
|
|
8143
|
+
"hasDynamicHelp": true,
|
|
8144
|
+
"multiple": false,
|
|
8145
|
+
"type": "option"
|
|
8146
|
+
}
|
|
8147
|
+
},
|
|
8148
|
+
"hasDynamicHelp": true,
|
|
8149
|
+
"hiddenAliases": [],
|
|
8150
|
+
"id": "hardis:org:purge:flow",
|
|
8151
|
+
"pluginAlias": "sfdx-hardis",
|
|
8152
|
+
"pluginName": "sfdx-hardis",
|
|
8153
|
+
"pluginType": "core",
|
|
8154
|
+
"strict": true,
|
|
8155
|
+
"enableJsonFlag": true,
|
|
8156
|
+
"title": "Purge Flow versions",
|
|
8157
|
+
"requiresProject": false,
|
|
8158
|
+
"isESM": true,
|
|
8159
|
+
"relativePath": [
|
|
8160
|
+
"lib",
|
|
8161
|
+
"commands",
|
|
8162
|
+
"hardis",
|
|
8163
|
+
"org",
|
|
8164
|
+
"purge",
|
|
8165
|
+
"flow.js"
|
|
8166
|
+
],
|
|
8167
|
+
"aliasPermutations": [],
|
|
8168
|
+
"permutations": [
|
|
8169
|
+
"hardis:org:purge:flow",
|
|
8170
|
+
"org:hardis:purge:flow",
|
|
8171
|
+
"org:purge:hardis:flow",
|
|
8172
|
+
"org:purge:flow:hardis",
|
|
8173
|
+
"hardis:purge:org:flow",
|
|
8174
|
+
"purge:hardis:org:flow",
|
|
8175
|
+
"purge:org:hardis:flow",
|
|
8176
|
+
"purge:org:flow:hardis",
|
|
8177
|
+
"hardis:purge:flow:org",
|
|
8178
|
+
"purge:hardis:flow:org",
|
|
8179
|
+
"purge:flow:hardis:org",
|
|
8180
|
+
"purge:flow:org:hardis",
|
|
8181
|
+
"hardis:org:flow:purge",
|
|
8182
|
+
"org:hardis:flow:purge",
|
|
8183
|
+
"org:flow:hardis:purge",
|
|
8184
|
+
"org:flow:purge:hardis",
|
|
8185
|
+
"hardis:flow:org:purge",
|
|
8186
|
+
"flow:hardis:org:purge",
|
|
8187
|
+
"flow:org:hardis:purge",
|
|
8188
|
+
"flow:org:purge:hardis",
|
|
8189
|
+
"hardis:flow:purge:org",
|
|
8190
|
+
"flow:hardis:purge:org",
|
|
8191
|
+
"flow:purge:hardis:org",
|
|
8192
|
+
"flow:purge:org:hardis"
|
|
8193
|
+
]
|
|
8194
|
+
},
|
|
8195
|
+
"hardis:org:retrieve:packageconfig": {
|
|
8196
|
+
"aliases": [],
|
|
8197
|
+
"args": {},
|
|
8198
|
+
"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<details markdown=\"1\">\n<summary>Technical explanations</summary>\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</details>\n",
|
|
8199
|
+
"examples": [
|
|
8200
|
+
"$ sf hardis:org:retrieve:packageconfig",
|
|
8201
|
+
"sf hardis:org:retrieve:packageconfig -u myOrg"
|
|
8202
|
+
],
|
|
8203
|
+
"flags": {
|
|
8204
|
+
"json": {
|
|
8205
|
+
"description": "Format output as json.",
|
|
8206
|
+
"helpGroup": "GLOBAL",
|
|
8207
|
+
"name": "json",
|
|
8208
|
+
"allowNo": false,
|
|
8209
|
+
"type": "boolean"
|
|
8210
|
+
},
|
|
8211
|
+
"flags-dir": {
|
|
8212
|
+
"helpGroup": "GLOBAL",
|
|
8213
|
+
"name": "flags-dir",
|
|
8214
|
+
"summary": "Import flag values from a directory.",
|
|
8108
8215
|
"hasDynamicHelp": false,
|
|
8109
8216
|
"multiple": false,
|
|
8110
8217
|
"type": "option"
|
|
@@ -8147,13 +8254,13 @@
|
|
|
8147
8254
|
},
|
|
8148
8255
|
"hasDynamicHelp": true,
|
|
8149
8256
|
"hiddenAliases": [],
|
|
8150
|
-
"id": "hardis:org:
|
|
8257
|
+
"id": "hardis:org:retrieve:packageconfig",
|
|
8151
8258
|
"pluginAlias": "sfdx-hardis",
|
|
8152
8259
|
"pluginName": "sfdx-hardis",
|
|
8153
8260
|
"pluginType": "core",
|
|
8154
8261
|
"strict": true,
|
|
8155
8262
|
"enableJsonFlag": true,
|
|
8156
|
-
"title": "
|
|
8263
|
+
"title": "Retrieve package configuration from an org",
|
|
8157
8264
|
"requiresProject": false,
|
|
8158
8265
|
"isESM": true,
|
|
8159
8266
|
"relativePath": [
|
|
@@ -8161,35 +8268,35 @@
|
|
|
8161
8268
|
"commands",
|
|
8162
8269
|
"hardis",
|
|
8163
8270
|
"org",
|
|
8164
|
-
"
|
|
8165
|
-
"
|
|
8271
|
+
"retrieve",
|
|
8272
|
+
"packageconfig.js"
|
|
8166
8273
|
],
|
|
8167
8274
|
"aliasPermutations": [],
|
|
8168
8275
|
"permutations": [
|
|
8169
|
-
"hardis:org:
|
|
8170
|
-
"org:hardis:
|
|
8171
|
-
"org:
|
|
8172
|
-
"org:
|
|
8173
|
-
"hardis:
|
|
8174
|
-
"
|
|
8175
|
-
"
|
|
8176
|
-
"
|
|
8177
|
-
"hardis:
|
|
8178
|
-
"
|
|
8179
|
-
"
|
|
8180
|
-
"
|
|
8181
|
-
"hardis:org:
|
|
8182
|
-
"org:hardis:
|
|
8183
|
-
"org:
|
|
8184
|
-
"org:
|
|
8185
|
-
"hardis:
|
|
8186
|
-
"
|
|
8187
|
-
"
|
|
8188
|
-
"
|
|
8189
|
-
"hardis:
|
|
8190
|
-
"
|
|
8191
|
-
"
|
|
8192
|
-
"
|
|
8276
|
+
"hardis:org:retrieve:packageconfig",
|
|
8277
|
+
"org:hardis:retrieve:packageconfig",
|
|
8278
|
+
"org:retrieve:hardis:packageconfig",
|
|
8279
|
+
"org:retrieve:packageconfig:hardis",
|
|
8280
|
+
"hardis:retrieve:org:packageconfig",
|
|
8281
|
+
"retrieve:hardis:org:packageconfig",
|
|
8282
|
+
"retrieve:org:hardis:packageconfig",
|
|
8283
|
+
"retrieve:org:packageconfig:hardis",
|
|
8284
|
+
"hardis:retrieve:packageconfig:org",
|
|
8285
|
+
"retrieve:hardis:packageconfig:org",
|
|
8286
|
+
"retrieve:packageconfig:hardis:org",
|
|
8287
|
+
"retrieve:packageconfig:org:hardis",
|
|
8288
|
+
"hardis:org:packageconfig:retrieve",
|
|
8289
|
+
"org:hardis:packageconfig:retrieve",
|
|
8290
|
+
"org:packageconfig:hardis:retrieve",
|
|
8291
|
+
"org:packageconfig:retrieve:hardis",
|
|
8292
|
+
"hardis:packageconfig:org:retrieve",
|
|
8293
|
+
"packageconfig:hardis:org:retrieve",
|
|
8294
|
+
"packageconfig:org:hardis:retrieve",
|
|
8295
|
+
"packageconfig:org:retrieve:hardis",
|
|
8296
|
+
"hardis:packageconfig:retrieve:org",
|
|
8297
|
+
"packageconfig:hardis:retrieve:org",
|
|
8298
|
+
"packageconfig:retrieve:hardis:org",
|
|
8299
|
+
"packageconfig:retrieve:org:hardis"
|
|
8193
8300
|
]
|
|
8194
8301
|
},
|
|
8195
8302
|
"hardis:org:refresh:after-refresh": {
|
|
@@ -8431,113 +8538,6 @@
|
|
|
8431
8538
|
"before-refresh:refresh:org:hardis"
|
|
8432
8539
|
]
|
|
8433
8540
|
},
|
|
8434
|
-
"hardis:org:retrieve:packageconfig": {
|
|
8435
|
-
"aliases": [],
|
|
8436
|
-
"args": {},
|
|
8437
|
-
"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<details markdown=\"1\">\n<summary>Technical explanations</summary>\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</details>\n",
|
|
8438
|
-
"examples": [
|
|
8439
|
-
"$ sf hardis:org:retrieve:packageconfig",
|
|
8440
|
-
"sf hardis:org:retrieve:packageconfig -u myOrg"
|
|
8441
|
-
],
|
|
8442
|
-
"flags": {
|
|
8443
|
-
"json": {
|
|
8444
|
-
"description": "Format output as json.",
|
|
8445
|
-
"helpGroup": "GLOBAL",
|
|
8446
|
-
"name": "json",
|
|
8447
|
-
"allowNo": false,
|
|
8448
|
-
"type": "boolean"
|
|
8449
|
-
},
|
|
8450
|
-
"flags-dir": {
|
|
8451
|
-
"helpGroup": "GLOBAL",
|
|
8452
|
-
"name": "flags-dir",
|
|
8453
|
-
"summary": "Import flag values from a directory.",
|
|
8454
|
-
"hasDynamicHelp": false,
|
|
8455
|
-
"multiple": false,
|
|
8456
|
-
"type": "option"
|
|
8457
|
-
},
|
|
8458
|
-
"debug": {
|
|
8459
|
-
"char": "d",
|
|
8460
|
-
"description": "Activate debug mode (more logs)",
|
|
8461
|
-
"name": "debug",
|
|
8462
|
-
"allowNo": false,
|
|
8463
|
-
"type": "boolean"
|
|
8464
|
-
},
|
|
8465
|
-
"websocket": {
|
|
8466
|
-
"description": "Websocket host:port for VsCode SFDX Hardis UI integration",
|
|
8467
|
-
"name": "websocket",
|
|
8468
|
-
"hasDynamicHelp": false,
|
|
8469
|
-
"multiple": false,
|
|
8470
|
-
"type": "option"
|
|
8471
|
-
},
|
|
8472
|
-
"skipauth": {
|
|
8473
|
-
"description": "Skip authentication check when a default username is required",
|
|
8474
|
-
"name": "skipauth",
|
|
8475
|
-
"allowNo": false,
|
|
8476
|
-
"type": "boolean"
|
|
8477
|
-
},
|
|
8478
|
-
"target-org": {
|
|
8479
|
-
"aliases": [
|
|
8480
|
-
"targetusername",
|
|
8481
|
-
"u"
|
|
8482
|
-
],
|
|
8483
|
-
"char": "o",
|
|
8484
|
-
"deprecateAliases": true,
|
|
8485
|
-
"name": "target-org",
|
|
8486
|
-
"noCacheDefault": true,
|
|
8487
|
-
"required": true,
|
|
8488
|
-
"summary": "Username or alias of the target org. Not required if the `target-org` configuration variable is already set.",
|
|
8489
|
-
"hasDynamicHelp": true,
|
|
8490
|
-
"multiple": false,
|
|
8491
|
-
"type": "option"
|
|
8492
|
-
}
|
|
8493
|
-
},
|
|
8494
|
-
"hasDynamicHelp": true,
|
|
8495
|
-
"hiddenAliases": [],
|
|
8496
|
-
"id": "hardis:org:retrieve:packageconfig",
|
|
8497
|
-
"pluginAlias": "sfdx-hardis",
|
|
8498
|
-
"pluginName": "sfdx-hardis",
|
|
8499
|
-
"pluginType": "core",
|
|
8500
|
-
"strict": true,
|
|
8501
|
-
"enableJsonFlag": true,
|
|
8502
|
-
"title": "Retrieve package configuration from an org",
|
|
8503
|
-
"requiresProject": false,
|
|
8504
|
-
"isESM": true,
|
|
8505
|
-
"relativePath": [
|
|
8506
|
-
"lib",
|
|
8507
|
-
"commands",
|
|
8508
|
-
"hardis",
|
|
8509
|
-
"org",
|
|
8510
|
-
"retrieve",
|
|
8511
|
-
"packageconfig.js"
|
|
8512
|
-
],
|
|
8513
|
-
"aliasPermutations": [],
|
|
8514
|
-
"permutations": [
|
|
8515
|
-
"hardis:org:retrieve:packageconfig",
|
|
8516
|
-
"org:hardis:retrieve:packageconfig",
|
|
8517
|
-
"org:retrieve:hardis:packageconfig",
|
|
8518
|
-
"org:retrieve:packageconfig:hardis",
|
|
8519
|
-
"hardis:retrieve:org:packageconfig",
|
|
8520
|
-
"retrieve:hardis:org:packageconfig",
|
|
8521
|
-
"retrieve:org:hardis:packageconfig",
|
|
8522
|
-
"retrieve:org:packageconfig:hardis",
|
|
8523
|
-
"hardis:retrieve:packageconfig:org",
|
|
8524
|
-
"retrieve:hardis:packageconfig:org",
|
|
8525
|
-
"retrieve:packageconfig:hardis:org",
|
|
8526
|
-
"retrieve:packageconfig:org:hardis",
|
|
8527
|
-
"hardis:org:packageconfig:retrieve",
|
|
8528
|
-
"org:hardis:packageconfig:retrieve",
|
|
8529
|
-
"org:packageconfig:hardis:retrieve",
|
|
8530
|
-
"org:packageconfig:retrieve:hardis",
|
|
8531
|
-
"hardis:packageconfig:org:retrieve",
|
|
8532
|
-
"packageconfig:hardis:org:retrieve",
|
|
8533
|
-
"packageconfig:org:hardis:retrieve",
|
|
8534
|
-
"packageconfig:org:retrieve:hardis",
|
|
8535
|
-
"hardis:packageconfig:retrieve:org",
|
|
8536
|
-
"packageconfig:hardis:retrieve:org",
|
|
8537
|
-
"packageconfig:retrieve:hardis:org",
|
|
8538
|
-
"packageconfig:retrieve:org:hardis"
|
|
8539
|
-
]
|
|
8540
|
-
},
|
|
8541
8541
|
"hardis:org:test:apex": {
|
|
8542
8542
|
"aliases": [],
|
|
8543
8543
|
"args": {},
|
|
@@ -9734,12 +9734,103 @@
|
|
|
9734
9734
|
"duplicatefiles:audit:project:hardis"
|
|
9735
9735
|
]
|
|
9736
9736
|
},
|
|
9737
|
-
"hardis:project:audit:remotesites": {
|
|
9737
|
+
"hardis:project:audit:remotesites": {
|
|
9738
|
+
"aliases": [],
|
|
9739
|
+
"args": {},
|
|
9740
|
+
"description": "\n## Command Behavior\n\n**Audits Salesforce Remote Site Settings in your project, providing a comprehensive overview of external endpoints accessed by your Salesforce org.**\n\nThis command is crucial for security reviews, compliance checks, and understanding the external integrations of your Salesforce environment. It helps identify all configured remote sites, their URLs, activity status, and associated protocols.\n\nKey functionalities:\n\n- **Remote Site Discovery:** Scans your project for RemoteSiteSetting metadata files (.remoteSite-meta.xml or .remoteSite).\n- **URL Extraction:** Extracts the URL, active status, and description for each remote site.\n- **Protocol and Domain Identification:** Determines the protocol (HTTP/HTTPS) and extracts the domain from each URL, providing a clearer picture of the external systems being accessed.\n- **Reporting:** Generates a CSV report summarizing all detected remote sites, including their protocol, domain, name, URL, active status, and description.\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 RemoteSiteSetting metadata files within the project.\n- **Content Analysis:** Reads the content of each XML file and uses regular expressions (/<url>(.*?)<\\/url>/gim, /<isActive>(.*?)<\\/isActive>/gim, /<description>(.*?)<\\/description>/gim) to extract relevant details.\n- **`catchMatches` Utility:** This utility function is used to apply the defined regular expressions to each file and extract all matching occurrences.\n- **URL Parsing:** Uses Node.js's `url` module to parse the extracted URLs and `psl` (Public Suffix List) to extract the domain name from the hostname.\n- **Data Structuring:** Organizes the extracted information into a structured format, including the remote site's name, file name, namespace, URL, active status, description, protocol, and domain.\n- **Reporting:** Uses `generateReports` to create a CSV report and display a table in the console, summarizing the audit findings.\n</details>\n",
|
|
9741
|
+
"examples": [
|
|
9742
|
+
"$ sf hardis:project:audit:remotesites"
|
|
9743
|
+
],
|
|
9744
|
+
"flags": {
|
|
9745
|
+
"json": {
|
|
9746
|
+
"description": "Format output as json.",
|
|
9747
|
+
"helpGroup": "GLOBAL",
|
|
9748
|
+
"name": "json",
|
|
9749
|
+
"allowNo": false,
|
|
9750
|
+
"type": "boolean"
|
|
9751
|
+
},
|
|
9752
|
+
"flags-dir": {
|
|
9753
|
+
"helpGroup": "GLOBAL",
|
|
9754
|
+
"name": "flags-dir",
|
|
9755
|
+
"summary": "Import flag values from a directory.",
|
|
9756
|
+
"hasDynamicHelp": false,
|
|
9757
|
+
"multiple": false,
|
|
9758
|
+
"type": "option"
|
|
9759
|
+
},
|
|
9760
|
+
"debug": {
|
|
9761
|
+
"char": "d",
|
|
9762
|
+
"description": "Activate debug mode (more logs)",
|
|
9763
|
+
"name": "debug",
|
|
9764
|
+
"allowNo": false,
|
|
9765
|
+
"type": "boolean"
|
|
9766
|
+
},
|
|
9767
|
+
"websocket": {
|
|
9768
|
+
"description": "Websocket host:port for VsCode SFDX Hardis UI integration",
|
|
9769
|
+
"name": "websocket",
|
|
9770
|
+
"hasDynamicHelp": false,
|
|
9771
|
+
"multiple": false,
|
|
9772
|
+
"type": "option"
|
|
9773
|
+
},
|
|
9774
|
+
"skipauth": {
|
|
9775
|
+
"description": "Skip authentication check when a default username is required",
|
|
9776
|
+
"name": "skipauth",
|
|
9777
|
+
"allowNo": false,
|
|
9778
|
+
"type": "boolean"
|
|
9779
|
+
}
|
|
9780
|
+
},
|
|
9781
|
+
"hasDynamicHelp": false,
|
|
9782
|
+
"hiddenAliases": [],
|
|
9783
|
+
"id": "hardis:project:audit:remotesites",
|
|
9784
|
+
"pluginAlias": "sfdx-hardis",
|
|
9785
|
+
"pluginName": "sfdx-hardis",
|
|
9786
|
+
"pluginType": "core",
|
|
9787
|
+
"strict": true,
|
|
9788
|
+
"enableJsonFlag": true,
|
|
9789
|
+
"title": "Audit Remote Sites",
|
|
9790
|
+
"requiresProject": true,
|
|
9791
|
+
"isESM": true,
|
|
9792
|
+
"relativePath": [
|
|
9793
|
+
"lib",
|
|
9794
|
+
"commands",
|
|
9795
|
+
"hardis",
|
|
9796
|
+
"project",
|
|
9797
|
+
"audit",
|
|
9798
|
+
"remotesites.js"
|
|
9799
|
+
],
|
|
9800
|
+
"aliasPermutations": [],
|
|
9801
|
+
"permutations": [
|
|
9802
|
+
"hardis:project:audit:remotesites",
|
|
9803
|
+
"project:hardis:audit:remotesites",
|
|
9804
|
+
"project:audit:hardis:remotesites",
|
|
9805
|
+
"project:audit:remotesites:hardis",
|
|
9806
|
+
"hardis:audit:project:remotesites",
|
|
9807
|
+
"audit:hardis:project:remotesites",
|
|
9808
|
+
"audit:project:hardis:remotesites",
|
|
9809
|
+
"audit:project:remotesites:hardis",
|
|
9810
|
+
"hardis:audit:remotesites:project",
|
|
9811
|
+
"audit:hardis:remotesites:project",
|
|
9812
|
+
"audit:remotesites:hardis:project",
|
|
9813
|
+
"audit:remotesites:project:hardis",
|
|
9814
|
+
"hardis:project:remotesites:audit",
|
|
9815
|
+
"project:hardis:remotesites:audit",
|
|
9816
|
+
"project:remotesites:hardis:audit",
|
|
9817
|
+
"project:remotesites:audit:hardis",
|
|
9818
|
+
"hardis:remotesites:project:audit",
|
|
9819
|
+
"remotesites:hardis:project:audit",
|
|
9820
|
+
"remotesites:project:hardis:audit",
|
|
9821
|
+
"remotesites:project:audit:hardis",
|
|
9822
|
+
"hardis:remotesites:audit:project",
|
|
9823
|
+
"remotesites:hardis:audit:project",
|
|
9824
|
+
"remotesites:audit:hardis:project",
|
|
9825
|
+
"remotesites:audit:project:hardis"
|
|
9826
|
+
]
|
|
9827
|
+
},
|
|
9828
|
+
"hardis:project:configure:auth": {
|
|
9738
9829
|
"aliases": [],
|
|
9739
9830
|
"args": {},
|
|
9740
|
-
"description": "\n## Command Behavior\n\n**
|
|
9831
|
+
"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",
|
|
9741
9832
|
"examples": [
|
|
9742
|
-
"$ sf hardis:project:
|
|
9833
|
+
"$ sf hardis:project:configure:auth"
|
|
9743
9834
|
],
|
|
9744
9835
|
"flags": {
|
|
9745
9836
|
"json": {
|
|
@@ -9757,6 +9848,13 @@
|
|
|
9757
9848
|
"multiple": false,
|
|
9758
9849
|
"type": "option"
|
|
9759
9850
|
},
|
|
9851
|
+
"devhub": {
|
|
9852
|
+
"char": "b",
|
|
9853
|
+
"description": "Configure project DevHub",
|
|
9854
|
+
"name": "devhub",
|
|
9855
|
+
"allowNo": false,
|
|
9856
|
+
"type": "boolean"
|
|
9857
|
+
},
|
|
9760
9858
|
"debug": {
|
|
9761
9859
|
"char": "d",
|
|
9762
9860
|
"description": "Activate debug mode (more logs)",
|
|
@@ -9776,53 +9874,84 @@
|
|
|
9776
9874
|
"name": "skipauth",
|
|
9777
9875
|
"allowNo": false,
|
|
9778
9876
|
"type": "boolean"
|
|
9877
|
+
},
|
|
9878
|
+
"target-org": {
|
|
9879
|
+
"aliases": [
|
|
9880
|
+
"targetusername",
|
|
9881
|
+
"u"
|
|
9882
|
+
],
|
|
9883
|
+
"char": "o",
|
|
9884
|
+
"deprecateAliases": true,
|
|
9885
|
+
"name": "target-org",
|
|
9886
|
+
"noCacheDefault": true,
|
|
9887
|
+
"summary": "Username or alias of the target org.",
|
|
9888
|
+
"hasDynamicHelp": true,
|
|
9889
|
+
"multiple": false,
|
|
9890
|
+
"type": "option"
|
|
9891
|
+
},
|
|
9892
|
+
"target-dev-hub": {
|
|
9893
|
+
"aliases": [
|
|
9894
|
+
"targetdevhubusername"
|
|
9895
|
+
],
|
|
9896
|
+
"char": "v",
|
|
9897
|
+
"deprecateAliases": true,
|
|
9898
|
+
"name": "target-dev-hub",
|
|
9899
|
+
"noCacheDefault": true,
|
|
9900
|
+
"required": false,
|
|
9901
|
+
"summary": "Username or alias of the Dev Hub org.",
|
|
9902
|
+
"hasDynamicHelp": true,
|
|
9903
|
+
"multiple": false,
|
|
9904
|
+
"type": "option"
|
|
9779
9905
|
}
|
|
9780
9906
|
},
|
|
9781
|
-
"hasDynamicHelp":
|
|
9907
|
+
"hasDynamicHelp": true,
|
|
9782
9908
|
"hiddenAliases": [],
|
|
9783
|
-
"id": "hardis:project:
|
|
9909
|
+
"id": "hardis:project:configure:auth",
|
|
9784
9910
|
"pluginAlias": "sfdx-hardis",
|
|
9785
9911
|
"pluginName": "sfdx-hardis",
|
|
9786
9912
|
"pluginType": "core",
|
|
9787
9913
|
"strict": true,
|
|
9788
9914
|
"enableJsonFlag": true,
|
|
9789
|
-
"title": "
|
|
9790
|
-
"requiresProject":
|
|
9915
|
+
"title": "Configure authentication",
|
|
9916
|
+
"requiresProject": false,
|
|
9917
|
+
"requiresDependencies": [
|
|
9918
|
+
"openssl"
|
|
9919
|
+
],
|
|
9791
9920
|
"isESM": true,
|
|
9792
9921
|
"relativePath": [
|
|
9793
9922
|
"lib",
|
|
9794
9923
|
"commands",
|
|
9795
9924
|
"hardis",
|
|
9796
9925
|
"project",
|
|
9797
|
-
"
|
|
9798
|
-
"
|
|
9926
|
+
"configure",
|
|
9927
|
+
"auth.js"
|
|
9799
9928
|
],
|
|
9800
9929
|
"aliasPermutations": [],
|
|
9801
9930
|
"permutations": [
|
|
9802
|
-
"hardis:project:
|
|
9803
|
-
"project:hardis:
|
|
9804
|
-
"project:
|
|
9805
|
-
"project:
|
|
9806
|
-
"hardis:
|
|
9807
|
-
"
|
|
9808
|
-
"
|
|
9809
|
-
"
|
|
9810
|
-
"hardis:
|
|
9811
|
-
"
|
|
9812
|
-
"
|
|
9813
|
-
"
|
|
9814
|
-
"hardis:project:
|
|
9815
|
-
"project:hardis:
|
|
9816
|
-
"project:
|
|
9817
|
-
"project:
|
|
9818
|
-
"hardis:
|
|
9819
|
-
"
|
|
9820
|
-
"
|
|
9821
|
-
"
|
|
9822
|
-
"hardis:
|
|
9823
|
-
"
|
|
9824
|
-
"
|
|
9825
|
-
"
|
|
9931
|
+
"hardis:project:configure:auth",
|
|
9932
|
+
"project:hardis:configure:auth",
|
|
9933
|
+
"project:configure:hardis:auth",
|
|
9934
|
+
"project:configure:auth:hardis",
|
|
9935
|
+
"hardis:configure:project:auth",
|
|
9936
|
+
"configure:hardis:project:auth",
|
|
9937
|
+
"configure:project:hardis:auth",
|
|
9938
|
+
"configure:project:auth:hardis",
|
|
9939
|
+
"hardis:configure:auth:project",
|
|
9940
|
+
"configure:hardis:auth:project",
|
|
9941
|
+
"configure:auth:hardis:project",
|
|
9942
|
+
"configure:auth:project:hardis",
|
|
9943
|
+
"hardis:project:auth:configure",
|
|
9944
|
+
"project:hardis:auth:configure",
|
|
9945
|
+
"project:auth:hardis:configure",
|
|
9946
|
+
"project:auth:configure:hardis",
|
|
9947
|
+
"hardis:auth:project:configure",
|
|
9948
|
+
"auth:hardis:project:configure",
|
|
9949
|
+
"auth:project:hardis:configure",
|
|
9950
|
+
"auth:project:configure:hardis",
|
|
9951
|
+
"hardis:auth:configure:project",
|
|
9952
|
+
"auth:hardis:configure:project",
|
|
9953
|
+
"auth:configure:hardis:project",
|
|
9954
|
+
"auth:configure:project:hardis"
|
|
9826
9955
|
]
|
|
9827
9956
|
},
|
|
9828
9957
|
"hardis:project:clean:emptyitems": {
|
|
@@ -11310,135 +11439,6 @@
|
|
|
11310
11439
|
"xml:clean:project:hardis"
|
|
11311
11440
|
]
|
|
11312
11441
|
},
|
|
11313
|
-
"hardis:project:configure:auth": {
|
|
11314
|
-
"aliases": [],
|
|
11315
|
-
"args": {},
|
|
11316
|
-
"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",
|
|
11317
|
-
"examples": [
|
|
11318
|
-
"$ sf hardis:project:configure:auth"
|
|
11319
|
-
],
|
|
11320
|
-
"flags": {
|
|
11321
|
-
"json": {
|
|
11322
|
-
"description": "Format output as json.",
|
|
11323
|
-
"helpGroup": "GLOBAL",
|
|
11324
|
-
"name": "json",
|
|
11325
|
-
"allowNo": false,
|
|
11326
|
-
"type": "boolean"
|
|
11327
|
-
},
|
|
11328
|
-
"flags-dir": {
|
|
11329
|
-
"helpGroup": "GLOBAL",
|
|
11330
|
-
"name": "flags-dir",
|
|
11331
|
-
"summary": "Import flag values from a directory.",
|
|
11332
|
-
"hasDynamicHelp": false,
|
|
11333
|
-
"multiple": false,
|
|
11334
|
-
"type": "option"
|
|
11335
|
-
},
|
|
11336
|
-
"devhub": {
|
|
11337
|
-
"char": "b",
|
|
11338
|
-
"description": "Configure project DevHub",
|
|
11339
|
-
"name": "devhub",
|
|
11340
|
-
"allowNo": false,
|
|
11341
|
-
"type": "boolean"
|
|
11342
|
-
},
|
|
11343
|
-
"debug": {
|
|
11344
|
-
"char": "d",
|
|
11345
|
-
"description": "Activate debug mode (more logs)",
|
|
11346
|
-
"name": "debug",
|
|
11347
|
-
"allowNo": false,
|
|
11348
|
-
"type": "boolean"
|
|
11349
|
-
},
|
|
11350
|
-
"websocket": {
|
|
11351
|
-
"description": "Websocket host:port for VsCode SFDX Hardis UI integration",
|
|
11352
|
-
"name": "websocket",
|
|
11353
|
-
"hasDynamicHelp": false,
|
|
11354
|
-
"multiple": false,
|
|
11355
|
-
"type": "option"
|
|
11356
|
-
},
|
|
11357
|
-
"skipauth": {
|
|
11358
|
-
"description": "Skip authentication check when a default username is required",
|
|
11359
|
-
"name": "skipauth",
|
|
11360
|
-
"allowNo": false,
|
|
11361
|
-
"type": "boolean"
|
|
11362
|
-
},
|
|
11363
|
-
"target-org": {
|
|
11364
|
-
"aliases": [
|
|
11365
|
-
"targetusername",
|
|
11366
|
-
"u"
|
|
11367
|
-
],
|
|
11368
|
-
"char": "o",
|
|
11369
|
-
"deprecateAliases": true,
|
|
11370
|
-
"name": "target-org",
|
|
11371
|
-
"noCacheDefault": true,
|
|
11372
|
-
"summary": "Username or alias of the target org.",
|
|
11373
|
-
"hasDynamicHelp": true,
|
|
11374
|
-
"multiple": false,
|
|
11375
|
-
"type": "option"
|
|
11376
|
-
},
|
|
11377
|
-
"target-dev-hub": {
|
|
11378
|
-
"aliases": [
|
|
11379
|
-
"targetdevhubusername"
|
|
11380
|
-
],
|
|
11381
|
-
"char": "v",
|
|
11382
|
-
"deprecateAliases": true,
|
|
11383
|
-
"name": "target-dev-hub",
|
|
11384
|
-
"noCacheDefault": true,
|
|
11385
|
-
"required": false,
|
|
11386
|
-
"summary": "Username or alias of the Dev Hub org.",
|
|
11387
|
-
"hasDynamicHelp": true,
|
|
11388
|
-
"multiple": false,
|
|
11389
|
-
"type": "option"
|
|
11390
|
-
}
|
|
11391
|
-
},
|
|
11392
|
-
"hasDynamicHelp": true,
|
|
11393
|
-
"hiddenAliases": [],
|
|
11394
|
-
"id": "hardis:project:configure:auth",
|
|
11395
|
-
"pluginAlias": "sfdx-hardis",
|
|
11396
|
-
"pluginName": "sfdx-hardis",
|
|
11397
|
-
"pluginType": "core",
|
|
11398
|
-
"strict": true,
|
|
11399
|
-
"enableJsonFlag": true,
|
|
11400
|
-
"title": "Configure authentication",
|
|
11401
|
-
"requiresProject": false,
|
|
11402
|
-
"requiresDependencies": [
|
|
11403
|
-
"openssl"
|
|
11404
|
-
],
|
|
11405
|
-
"isESM": true,
|
|
11406
|
-
"relativePath": [
|
|
11407
|
-
"lib",
|
|
11408
|
-
"commands",
|
|
11409
|
-
"hardis",
|
|
11410
|
-
"project",
|
|
11411
|
-
"configure",
|
|
11412
|
-
"auth.js"
|
|
11413
|
-
],
|
|
11414
|
-
"aliasPermutations": [],
|
|
11415
|
-
"permutations": [
|
|
11416
|
-
"hardis:project:configure:auth",
|
|
11417
|
-
"project:hardis:configure:auth",
|
|
11418
|
-
"project:configure:hardis:auth",
|
|
11419
|
-
"project:configure:auth:hardis",
|
|
11420
|
-
"hardis:configure:project:auth",
|
|
11421
|
-
"configure:hardis:project:auth",
|
|
11422
|
-
"configure:project:hardis:auth",
|
|
11423
|
-
"configure:project:auth:hardis",
|
|
11424
|
-
"hardis:configure:auth:project",
|
|
11425
|
-
"configure:hardis:auth:project",
|
|
11426
|
-
"configure:auth:hardis:project",
|
|
11427
|
-
"configure:auth:project:hardis",
|
|
11428
|
-
"hardis:project:auth:configure",
|
|
11429
|
-
"project:hardis:auth:configure",
|
|
11430
|
-
"project:auth:hardis:configure",
|
|
11431
|
-
"project:auth:configure:hardis",
|
|
11432
|
-
"hardis:auth:project:configure",
|
|
11433
|
-
"auth:hardis:project:configure",
|
|
11434
|
-
"auth:project:hardis:configure",
|
|
11435
|
-
"auth:project:configure:hardis",
|
|
11436
|
-
"hardis:auth:configure:project",
|
|
11437
|
-
"auth:hardis:configure:project",
|
|
11438
|
-
"auth:configure:hardis:project",
|
|
11439
|
-
"auth:configure:project:hardis"
|
|
11440
|
-
]
|
|
11441
|
-
},
|
|
11442
11442
|
"hardis:project:convert:profilestopermsets": {
|
|
11443
11443
|
"aliases": [],
|
|
11444
11444
|
"args": {},
|
|
@@ -15505,5 +15505,5 @@
|
|
|
15505
15505
|
]
|
|
15506
15506
|
}
|
|
15507
15507
|
},
|
|
15508
|
-
"version": "6.12.
|
|
15508
|
+
"version": "6.12.3"
|
|
15509
15509
|
}
|