Last active
January 29, 2025 07:52
-
-
Save kartben/7d7001cbf75e0e7ffda8e73120b13a86 to your computer and use it in GitHub Desktop.
PRs with failed compliance check
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
gh pr list --state open --json number,title,url,statusCheckRollup --limit 50 -S "status:failure" \ | |
| jq -r ' | |
.[] | | |
. as $pr | | |
[ $pr.statusCheckRollup[]? | | |
select( | |
.__typename == "CheckRun" and | |
(.name | contains("Run compliance checks")) and | |
.conclusion == "FAILURE" | |
) | |
] as $checks | | |
select($checks | length > 0) | | |
"PR #\($pr.number): \($pr.title)\nURL: \($pr.url)\nCompliance Checks Status:", | |
( $checks[] | " - \(.name): \(.conclusion)" ), | |
"" | |
' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment