From 49e9a0748b97ebd958dfc5b6f35adf9983a658f8 Mon Sep 17 00:00:00 2001 From: Fabien Potencier Date: Wed, 8 May 2024 18:22:11 +0200 Subject: [PATCH] Simplify code --- .goreleaser.yml | 2 +- main.go | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.goreleaser.yml b/.goreleaser.yml index 4e8cf03..b8f29bb 100644 --- a/.goreleaser.yml +++ b/.goreleaser.yml @@ -30,4 +30,4 @@ checksum: snapshot: name_template: "{{ .Tag }}-next" changelog: - skip: true + disable: true diff --git a/main.go b/main.go index 39b3ef9..3277daf 100644 --- a/main.go +++ b/main.go @@ -86,7 +86,7 @@ func main() { f, err := os.OpenFile(gOutFile, os.O_APPEND|os.O_CREATE|os.O_WRONLY, 0644) if err != nil { - fmt.Fprintf(os.Stderr, fmt.Sprintf("unable to open github output: %s\n", err)) + fmt.Fprintf(os.Stderr, "unable to open github output: %s\n", err) os.Exit(127) } defer f.Close() @@ -94,7 +94,7 @@ func main() { // inside a Github action, export vulns if output, err := security.Format(vulns, "raw_json"); err == nil { if _, err = f.WriteString("vulns=" + string(output) + "\n"); err != nil { - fmt.Fprintf(os.Stderr, fmt.Sprintf("unable to write into github output: %s\n", err)) + fmt.Fprintf(os.Stderr, "unable to write into github output: %s\n", err) os.Exit(127) } }