Well… Maybe we do. This is a quick plug (no reimbursement of any kind) for the folks over at Shields.io, who make creating custom badges for readme files and websites an easy and fun task.
A Quick Demo
The badges above are generated from Shields.io. The first link looks like this:
https://img.shields.io/github/license/spyder007/MMM-PrometheusAlerts
My Github username (spyder007
) and the repository name (MMM-PrometheusAlerts
) are used in the Image URL, which generates the badge. The second one, build status, looks like this:
https://img.shields.io/github/actions/workflow/status/spyder007/MMM-PrometheusAlerts/node.js.yml
In this case, my Github username and the repository name remain the same, but node.js.yml
is the name of the workflow file for which I want to display the status.
Every badge in Shields.io has a “builder” page that explains how to build the image and even allows you to override styles, colors, and labels, and even add logos from any icon in the Simple Icons collection.
Some examples of alterations to my build status above:
Too many options to list…
Now, these are live badges, meaning, if my build fails, the green “passing” will go to a red “failing.” Shields.io does this by using the variety of APIs available to gather data about builds, code coverage, licenses, chat, sizes and download counts, funding, issue tracking… It’s a lot. But the beauty of it is, you can create Readme files or websites which have easy to read visuals. My PI Monitoring repository‘s Readme makes use of a number of these shields to give you a quick look at the status of the repo.