Skip to content

Commit

Permalink
add checks array in JSON output
Browse files Browse the repository at this point in the history
  • Loading branch information
Jozef Reisinger committed Nov 16, 2021
1 parent 289ddd2 commit 4bc9758
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion cli/cli.go
Original file line number Diff line number Diff line change
Expand Up @@ -41,8 +41,13 @@ func (rs Results) PrintJSON() {
if len(rs) == 0 {
return
}
out := struct {
Check Results `json:"checks"`
}{
rs,
}
enc := json.NewEncoder(os.Stdout)
if err := enc.Encode(rs); err != nil {
if err := enc.Encode(out); err != nil {
log.Fatal(err)
}
}
Expand Down

0 comments on commit 4bc9758

Please sign in to comment.