docs: ADR-0003: customization of list output #103
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
3. List output customization
Date: 2024-07-11
Status
Accepted
Context
This is an enhancement proposal to allow users to customize the output of
bomctl list
that listsSBOM Documents by specifying a search expression, filter, or template.
Decision
Update
bomctl list
to accept an expression to customize the output table of SBOM documents.This would be similar in functionality to the
--format
option used by variousdocker
commands.Either the existing use of positional argument will be retained, or an additional flag (such as
--format
or--query
) will be added.The supported search/filter expression syntaxes will be:
The expression would then be parsed to construct a SQL query or call to the
ent
backend toretrieve and display the desired table(s)/column(s).
A separate
bomctl query
command will be used to query/filter nodes,bomctl list
is reservedfor finding SBOM Documents.
@puerco recommended reading the store into CEL to simplify listing.
Consequences
This change would allow users greater control over inspecting the contents of their cached SBOMs.