Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve the generated template README #224

Merged
merged 1 commit into from
Jul 16, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 9 additions & 8 deletions pkg/ctl/implementation.go
Original file line number Diff line number Diff line change
Expand Up @@ -47,21 +47,22 @@ const (
"`vexctl generate` when generating VEX data for a release or\n" +
"a specific artifact.\n\n" +
"To add new statements to publish data about a vulnerability,\n" +
"download [vexctl](https://github.com/openvex/vexctl)\n" +
"and append new statements using `vexctl add`. For example:\n\n" +
"download [vexctl] and append new statements using\n" +
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ah sorry

i think you can keep the link

Suggested change
"download [vexctl] and append new statements using\n" +
"download [vexctl](https://github.com/openvex/vexctl) and append new statements using\n" +

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The auto generated template will be like this, because it uses the shortcut reference link.


OpenVEX Templates Directory

This directory contains the OpenVEX data for this repository.
The files stored in this directory are used as templates by
vexctl generate when generating VEX data for a release or
a specific artifact.

To add new statements to publish data about a vulnerability,
download vexctl and append new statements using
vexctl add. For example:

vexctl add --in-place main.openvex.json --product pkg:oci/test --vuln CVE-2014-1234567 --status under_investigation

That will add a new VEX statement expressing that the impact of
CVE-2014-1234567 is under investigation in the test image. When
cutting a new release, for pkg:oci/test the new file can be
incorporated to the release's VEX data.

Read more about OpenVEX

To know more about generating, publishing and using VEX data
in your project, please check out the vexctl repository and
documentation
.

OpenVEX also has an examples repository with samples and docs.


We use the same shortcut in both references to vexctl, because the original target link is the same.

image

"`vexctl add`. For example:\n\n" +
"```\n" +
"vexctl add --in-place main.openvex.json pkg:oci/test CVE-2014-1234567 fixed\n" +
"vexctl add --in-place main.openvex.json --product pkg:oci/test --vuln CVE-2014-1234567 --status under_investigation\n" +
"```\n\n" +
"That will add a new VEX statement expressing that the impact of\n" +
"CVE-2014-1234567 is under investigation in the test image. When\n" +
"cutting a new release, for `pkg:oci/test` the new file will be\n" +
"incorporated to the relase's VEX data.\n\n" +
"cutting a new release, for `pkg:oci/test` the new file can be\n" +
"incorporated to the release's VEX data.\n\n" +
"## Read more about OpenVEX\n\n" +
"To know more about generating, publishing and using VEX data\n" +
"in your project, please check out the [vexctl repository and\n" +
"documentation](https://github.com/openvex/vexctl).\n\n" +
"OpenVEX also has an [examples repository](https://github.com/openvex/examples)\n" +
"with samples and docs.\n"
"documentation][vexctl].\n\n" +
"OpenVEX also has an [examples repository] with samples and docs.\n\n\n" +
"[vexctl]: https://github.com/openvex/vexctl\n" +
"[examples repository]: https://github.com/openvex/examples\n"
)

type Implementation interface {
Expand Down