()
| 48 | ) |
| 49 | |
| 50 | func usage() { |
| 51 | fmt.Fprintln(os.Stderr, "This is an example of how to verify the provenance of an artifact using GitHub Attestations and the sigstore-go library.") |
| 52 | fmt.Fprintf(os.Stderr, "\nUsage: %v [flags]\n", os.Args[0]) |
| 53 | fmt.Fprint(os.Stderr, "\nThe flags are:\n") |
| 54 | flag.PrintDefaults() |
| 55 | fmt.Fprintf(os.Stderr, ` |
| 56 | Example: |
| 57 | Verifying a GitHub CLI artifact |
| 58 | %v -owner cli \ |
| 59 | -artifact-digest 2ce2e480e3c3f7ca0af83418d3ebaeedacee135dbac94bd946d7d84edabcdb64 \ |
| 60 | -expected-san https://github.com/cli/cli/.github/workflows/deployment.yml@refs/heads/trunk |
| 61 | |
| 62 | See https://github.com/cli/cli/attestations/2543768 for a summary of the attestation. |
| 63 | `, os.Args[0]) |
| 64 | } |
| 65 | |
| 66 | func main() { |
| 67 | flag.Parse() |
no outgoing calls
no test coverage detected
searching dependent graphs…