Skip to content

Commit

Permalink
Handle plan preview workflow's error and exit with error status code (#…
Browse files Browse the repository at this point in the history
  • Loading branch information
TakumaKurosawa authored and ffjlabo committed Nov 13, 2023
1 parent ec4c52a commit 2eed512
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions tool/actions-plan-preview/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -141,6 +141,10 @@ func main() {
doComment(failureBadgeURL + "\nUnable to run plan-preview for a closed pull request.")
return
}
body := makeCommentBody(event, result)
doComment(failureBadgeURL + "\n" + body)
log.Println("plan-preview result has error")
os.Exit(1)
}

// Find comments we sent before
Expand Down

0 comments on commit 2eed512

Please sign in to comment.