@velaro/cli 1.4.202 → 1.4.203
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/lib/commands/compliance.js +25 -1
- package/package.json +1 -1
|
@@ -13,7 +13,8 @@ export const complianceCommand = {
|
|
|
13
13
|
.command(complianceAttestationCommand)
|
|
14
14
|
.command(complianceRedactionTestCommand)
|
|
15
15
|
.command(complianceRedactionStatusCommand)
|
|
16
|
-
.command(complianceRedactionEventsCommand)
|
|
16
|
+
.command(complianceRedactionEventsCommand)
|
|
17
|
+
.command(complianceReadinessCommand),
|
|
17
18
|
// Default: no subcommand = run status (same as `velaro compliance status`)
|
|
18
19
|
handler: runCommand(async () => { await runStatus(); }),
|
|
19
20
|
};
|
|
@@ -227,3 +228,26 @@ const complianceAttestationCommand = {
|
|
|
227
228
|
console.log('\n' + result.attestationText);
|
|
228
229
|
}),
|
|
229
230
|
};
|
|
231
|
+
|
|
232
|
+
// velaro compliance readiness: the Compliance Readiness checklist (settings turned on in your account).
|
|
233
|
+
const complianceReadinessCommand = {
|
|
234
|
+
command: 'readiness',
|
|
235
|
+
describe: 'Show the Compliance Readiness checklist (a check mark means a setting is on, not that it is legally sufficient)',
|
|
236
|
+
builder: (y) => y,
|
|
237
|
+
handler: runCommand(async () => {
|
|
238
|
+
const r = await get('/ComplianceReadiness');
|
|
239
|
+
console.log(`
|
|
240
|
+
Compliance Readiness: ${r.doneCount} of ${r.applicableCount} controls set up
|
|
241
|
+
${'-'.repeat(50)}`);
|
|
242
|
+
const mark = { done: '[x]', outstanding: '[ ]', notApplicable: '[-]', unknown: '[?]' };
|
|
243
|
+
for (const c of r.controls) {
|
|
244
|
+
const by = c.setUpBy ? ` by ${c.setUpBy}` : '';
|
|
245
|
+
const at = c.setUpAt ? ` on ${c.setUpAt}` : '';
|
|
246
|
+
console.log(`${mark[c.status] ?? '[?]'} ${c.title}: ${c.detail}${c.status === 'done' ? ` Set up${by}${at}.` : ''}`);
|
|
247
|
+
if (c.status === 'outstanding') console.log(` How to add: ${c.howTo} (${c.howToPath})`);
|
|
248
|
+
}
|
|
249
|
+
console.log(`
|
|
250
|
+
${r.footerNotice}
|
|
251
|
+
`);
|
|
252
|
+
}),
|
|
253
|
+
};
|
package/package.json
CHANGED