Skip to content

Commit 1ebac1d

Browse files
committed
revisit option descriptions
Signed-off-by: Jan Kowalleck <[email protected]>
1 parent b85dde9 commit 1ebac1d

File tree

2 files changed

+15
-36
lines changed

2 files changed

+15
-36
lines changed

README.md

Lines changed: 7 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -57,20 +57,13 @@ $ yarn CycloneDX make-sbom
5757
5858
━━━ Options ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
5959
60-
--spec-version #0 Which version of CycloneDX to use.
61-
(choices: "1.2", "1.3", "1.4", "1.5", default: "1.5")
62-
--output-format #0 Which output format to use.
63-
(choices: "JSON", "XML", default: "JSON")
64-
--output-file #0 Path to the output file. Set to "-" to write to STDOUT.
65-
(default: write to STDOUT)
66-
--production,--prod Exclude development dependencies.
67-
(defaults to 'true' if the environment variable "NODE_ENV" is set to "production"')
68-
--component-type #0 Type of component described by the generated SBOM. (choices: "application", "framework", "library", "container", "platform", "device-driver")
69-
Default: application
70-
--licenses Include license information for components in generated SBOM. License information will always be absent for components that don't specify licenses unambigously.
71-
Default: Licenses are not included in the SBOM.
72-
--reproducible Omit anything random or time-based from SBOM. If enabled consecutive runs of will result in identical files.
73-
Default: false
60+
--spec-version #0 Which version of CycloneDX to use. (choices: "1.2", "1.3", "1.4", "1.5", default: "1.5")
61+
--output-format #0 Which output format to use. (choices: "JSON", "XML", default: "JSON")
62+
--output-file #0 Path to the output file. Set to "-" to write to STDOUT (default: write to STDOUT)
63+
--production,--prod Exclude development dependencies. (default: true if the NODE_ENV environment variable is set to "production", otherwise false)
64+
--mc-type #0 Type of the main component. (choices: "application", "framework", "library", "container", "platform", "device-driver", default: "application")
65+
--licenses Include license information for components in generated SBOM. License information will always be absent for components that don't specify licenses unambiguously.
66+
--reproducible Whether to go the extra mile and make the output reproducible. This might result in loss of time- and random-based values.
7467
7568
━━━ Details ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
7669

sources/index.ts

Lines changed: 8 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -44,49 +44,35 @@ class SBOMCommand extends BaseCommand {
4444
});
4545

4646
specVersion = Option.String("--spec-version", {
47-
description: `Which version of CycloneDX to use.
48-
49-
(choices: "1.2", "1.3", "1.4", "1.5", default: "1.5")`,
47+
description: 'Which version of CycloneDX to use.\n(choices: "1.2", "1.3", "1.4", "1.5", default: "1.5")',
5048
});
5149

5250
outputFormat = Option.String("--output-format", {
53-
description: `Which output format to use.
54-
55-
(choices: "JSON", "XML", default: "JSON")`,
51+
description: 'Which output format to use.\n(choices: "JSON", "XML", default: "JSON")',
5652
});
5753

5854
outputFile = Option.String(`--output-file`, {
59-
description: `Path to the output file. Set to "-" to write to STDOUT.
60-
61-
(default: write to STDOUT)`,
55+
description: `Path to the output file.\nSet to "-" to write to STDOUT\n(default: write to STDOUT)`,
6256
});
6357

6458
/* mimic option from yarn.
6559
- see https://classic.yarnpkg.com/lang/en/docs/cli/install/#toc-yarn-install-production-true-false
6660
- see https://yarnpkg.com/cli/workspaces/focus
6761
*/
6862
production = Option.Boolean(`--production,--prod`, process.env.NODE_ENV=='production', {
69-
description: `Exclude development dependencies.
70-
71-
(defaults to 'true' if the environment variable "NODE_ENV" is set to "production"')`,
63+
description: 'Exclude development dependencies.\n(default: true if the NODE_ENV environment variable is set to "production", otherwise false)',
7264
});
7365

74-
componentType = Option.String("--component-type", {
75-
description: `Type of component described by the generated SBOM. (choices: "application", "framework", "library", "container", "platform", "device-driver")
76-
77-
Default: application`,
66+
componentType = Option.String("--mc-type", {
67+
description: 'Type of the main component.\n(choices: "application", "framework", "library", "container", "platform", "device-driver", default: "application")',
7868
});
7969

8070
licenses = Option.Boolean(`--licenses`, false, {
81-
description: `Include license information for components in generated SBOM. License information will always be absent for components that don't specify licenses unambigously.
82-
83-
Default: Licenses are not included in the SBOM.`,
71+
description: `Include license information for components in generated SBOM.\nLicense information will always be absent for components that don't specify licenses unambiguously.`,
8472
});
8573

8674
reproducible = Option.Boolean(`--reproducible`, false, {
87-
description: `Omit anything random or time-based from SBOM. If enabled consecutive runs of will result in identical files.
88-
89-
Default: false`,
75+
description: 'Whether to go the extra mile and make the output reproducible.\nThis might result in loss of time- and random-based values.',
9076
});
9177

9278
async execute() {

0 commit comments

Comments
 (0)