Skip to content
This repository has been archived by the owner on Jan 16, 2025. It is now read-only.

feat: include information for historical provenance #10

Merged
merged 2 commits into from
Apr 25, 2024
Merged

feat: include information for historical provenance #10

merged 2 commits into from
Apr 25, 2024

Conversation

yrobla
Copy link
Contributor

@yrobla yrobla commented Apr 25, 2024

Closes: #5

@yrobla yrobla requested a review from lukehinds April 25, 2024 09:39
Comment on lines 164 to 178
if result.Provenance.Description.Provenance.Issuer != "" {
reportBuilder.WriteString("### :key: Proof of origin (Provenance):\n")
reportBuilder.WriteString("Built and signed with sigstore using GitHub Actions.\n")
reportBuilder.WriteString(fmt.Sprintf("· Source repo: `%s`\n", result.Provenance.Description.Provenance.SourceRepo))
reportBuilder.WriteString(fmt.Sprintf("· Github Action Workflow: `%s`\n", result.Provenance.Description.Provenance.Workflow))
reportBuilder.WriteString(fmt.Sprintf("· Issuer: `%s`\n", result.Provenance.Description.Provenance.Issuer))
reportBuilder.WriteString(fmt.Sprintf("· Rekor Public Ledger: `%s`\n", result.Provenance.Description.Provenance.Transparency))
} else {
// need to write regular provenance info
reportBuilder.WriteString("### :key: Proof of origin (Provenance):\n")
reportBuilder.WriteString(fmt.Sprintf("# versions: %.0f\n", result.Provenance.Description.Hp.Versions))
reportBuilder.WriteString(fmt.Sprintf("# tags: %.0f\n", result.Provenance.Description.Hp.Tags))
reportBuilder.WriteString(fmt.Sprintf("# matched: %.0f\n", result.Provenance.Description.Hp.Common))
}

Copy link
Contributor

Choose a reason for hiding this comment

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

We should add some context what provenance means, could we maybe include the following link o lines 171 and 177

https://docs.stacklok.com/trusty/understand/provenance

You can use the text 'Learn more about source of origin provenance'

@yrobla yrobla merged commit 93044e4 into main Apr 25, 2024
1 check passed
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add details about provenance
2 participants