Closed jkowalleck closed 2 years ago
One thing that would be really useful to add (and hopefully can be determined during BOM creation) is whether or not a component has scripts that are executed upon install.
If this can be determined, adding cdx:npm:package:install-scripts-present
(boolean) would be really useful along with one or more of cdx:npm:package:install-script
with the value of the script.
Adding support for config, engines, and os would also be useful.
re: https://github.com/CycloneDX/cyclonedx-property-taxonomy/pull/21#issuecomment-1207481279
Adding support for config, engines, and os would also be useful.
i am not planning to fetch these information in my current implementation. and i did not want to propose a complete list of properties, just the ones i currently need.
As this is a living standard, the future will tell what to add, right?
in package,json
its written as https://docs.npmjs.com/cli/v8/configuring-npm/package-json#engines
example:
{
"engines": {
"node": ">=16.0.7",
"npm": "6 - 8"
}
}
Could be cdx:npm:engine:<NAME>
to represent this.
What do you thing?
in package,json
its written as https://docs.npmjs.com/cli/v8/configuring-npm/package-json#os
Could be cdx:npm:os
to represent this.
What do you thing?
in package,json
its written as https://docs.npmjs.com/cli/v8/configuring-npm/package-json#config
Could be cdx:npm:package:config:<NAME>
to represent this.
What do you thing?
I think the proposal for engine, os, and config are good. We should likely include it in the taxonomy even if you're not implementing them just yet. Others may choose to do so (e.g. CDXGen).
What are your thoughts on install scripts?
updated.
engine
and os
.config
and scripts
as i have currently no idea what the content should be. will leave it to the first person woh might implements/uses it. @stevespringett could you advice how a boolean value should be represented?
currently i went with case-sensitive true
/false
. is this okay?
could you advice how a boolean value should be represented? currently i went with case-sensitive true/false. is this okay?
I think that's ok. But question to the group... Is cdx:npm:package:install-scripts-present
valuable or can this be derived from the presence of one or more cdx:npm:package:install-script
?
install-scripts-present
seems redundant.
regarding install-time scripts: see https://docs.npmjs.com/cli/v8/using-npm/scripts#npm-install the list of all (custom) scripts that can run during the install phase. remember: each script may also call other scripts internally. remember: local installs run additional scripts, when the package is not pre-made.
thank you for the initial feedback. finalized the docs that i see in need for a merge. additions are welcome in later pull-requests, but the current {minimal} state is the one i'd love to see in the specs.
ready for review.
Thanks @jkowalleck. LGTM
closes #20
TODO
checklist for myself:
inBundle
when they are bundled with their parent