Print out the govulncheck.sarif file in CI

This commit is contained in:
Kovid Goyal 2025-09-24 12:57:21 +05:30
parent 04d708d597
commit 4771de3f95
No known key found for this signature in database
GPG key ID: 06BC317B515ACE7C

View file

@ -272,6 +272,8 @@ def main() -> None:
subprocess.check_call(['go', 'install', 'golang.org/x/vuln/cmd/govulncheck@latest'])
with open('govulncheck.sarif', 'wb') as f:
subprocess.check_call(['govulncheck', '-format', 'sarif', './...'], stdout=f)
with open('govulncheck.sarif') as f:
print(f.read())
elif action == 'gofmt':
q = subprocess.check_output('gofmt -s -l tools kittens'.split()).decode()
if q.strip():