-
-
Notifications
You must be signed in to change notification settings - Fork 5.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Badge Request: GitHub Check Runs Status #4364
Comments
Furthermore, the GH I shall attempt a PR for this :-) |
If no one is working on this issue, I would like to work on this. Thank you. |
There's PR #7759 for it already 😃 |
@mbtools just trying to wrap my head around all these different concepts. Is this new check runs badge effectively a replacement for the existing check status one? Or are there notable differences in what they represent? |
In the most simple terms, the new badge will match the green check, yellow dot, or red cross that you see in GitHub next to a commit. If the commit is the head of a branch or tag, you get the corresponding latest status. |
Sorry, I'm still not clear... What would you recommend we do with the existing |
my understanding was that the various options provide the flexibility/granularity to see both the aggregate rolled up status as well as the status for individual items, and that there were use cases and user desire for both |
Indeed. The new service works on repo level. It is therefore suitable to include such badge into READMEs for showing the latest status. In contrast, the other services require a workflow or pull request so show only the status of one particular object. |
New badge: Don't both of these allow checking the state of one particular object, a tag? |
Similar but not the same: Here's the best explanation I could find: https://stackoverflow.com/a/72312617 Imho, the description of the existing badge (#5973) should be changed to "GitHub tag status", "GitHub commit status", "GitHub branch status". Check runs are closely aligned with GH action and therefore preferred. To distinguish the new services (#7759) some more, I added an optional name filter so you can show the status of one particular check run (as was requested somewhere). |
Thanks for linking to those resources!
This makes sense to me. I also think we should add a description to those existing badges, possibly along the following lines:
What do you think? |
Sounds good. I will adjust the GH commit status in a separate PR. PS: It will have to wait until GH check run PR is merged because it comes from the main branch of my fork. I usually do branches but didn't think ahead here. |
The new badges are now live in production! 🎉 |
📋 Description
Status badge for check runs from GitHub.
🔗 Data
application/vnd.github.antiope-preview+json
) in the request header.API path would be:
/{{owner}}/{{repo}}/commits/{{branch}}/check-runs?check_name={{name}}
For example:
https://api.github.com/repos/rust-lang/mdBook/commits/master/check-runs?check_name=Rustfmt
🎤 Motivation
Check Runs (and Check Suites) reflect the status of various GitHub Apps/Integrations/Services/etc. and are most often seen in the
Checks
tab for a PR. See an example here in our repo which includes LGTM and Netlify.The primary use case I'd envision for this badge would be for a specific Job status as part of the GitHub Actions ecosystem. GitHub Workflows consist of one or more Jobs (and Jobs consist of a sequence of tasks/steps, where each step can run a command or action).
We already have the Workflow status badge, but a Check Runs status badge would allow for Job-level status badges too (plus it could be used for any other Check Run status)
The text was updated successfully, but these errors were encountered: