Skip to content

feat: host the README badge at commit-check.com/badge.svg - #46

Merged
shenxianpeng merged 1 commit into
mainfrom
feature/hosted-badge
Sep 27, 2026
Merged

shenxianpeng merged 1 commit into
mainfrom
feature/hosted-badge

Conversation

@shenxianpeng

@shenxianpeng shenxianpeng commented Sep 27, 2026 •

Copy link
Copy Markdown
Member

This serves the Commit Check badge from the site, so the snippet a user copies becomes one line:

[![commit-check](https://commit-check.com/badge.svg)](https://commit-check.com)

Today the snippet is a 519-character shields.io URL with the mark base64-encoded into it, and every page view makes a request to a third party. conventionalbranch.org/badge.svg already works this way.

What's in it

  • docs/badge.svg. This is a hand-written copy of the shields.io render of the brand badge from branding/README.md. It has the same 157×20 size, the same colors and flat style, and the same textLength, which keeps the text identical on machines without Verdana. The mark is drawn as vectors instead of an embedded image. A comment in the file explains all of this, including the contrast trade-off: white on Signal Blue is about 3:1, which is the color the badge has always had. MkDocs copies the file to the site root.
  • Getting started. A short Show that you use it section now shows the badge, with Markdown and reStructuredText snippets in tabs. Until now only the READMEs documented the badge.

Checks

  • I rendered both files with rsvg-convert at 6× and compared them with ImageMagick. At 8% fuzz, 0 pixels differ, and the RMSE is 1.5e-5.
  • mkdocs build --strict passes (with SOCIAL_CARDS=false). site/badge.svg is in the output, and the page links it as ../badge.svg.
  • python -m pytest tests/ -q passes with the released commit-check installed (10 tests). The pins and the changelog were already at 2.18.1, so nothing needed bringing into step.

After this deploys

Once https://commit-check.com/badge.svg is live, the long snippet elsewhere can switch to the short one:

The badge rows in those READMEs can stay on shields.io. Only the snippet users copy needs to change.

Summary by CodeRabbit

  • Documentation
    • Added a “Show that you use it” section with a commit-check badge and copyable Markdown and reStructuredText snippets.

The badge a README carries today is a shields.io URL with the Commit
Check mark base64-encoded into it: 519 characters to copy, and a
third-party request on every page view. conventionalbranch.org/badge.svg
already shows the alternative.

docs/badge.svg is a hand copy of what shields.io renders for the brand
badge -- same size, colors, flat style and textLength, with the mark
drawn as vectors instead of an embedded image. Rendered at 6x beside
the shields.io original, no pixel differs by more than 8%, so the two
look the same in a README row. MkDocs copies it to the site root.

Getting started gains a short "Show that you use it" section with the
Markdown and reStructuredText snippets. Until now only the READMEs
documented the badge.
@netlify

netlify Bot commented Sep 27, 2026 •

Copy link
Copy Markdown

✅ Deploy Preview for commit-check ready!

Name Link
🔨 Latest commit 0184665
🔍 Latest deploy log https://app.netlify.com/projects/commit-check/deploys/6ab940fde1aeb60008a2cb86
😎 Deploy Preview https://deploy-preview-46--commit-check.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

@coderabbitai

coderabbitai Bot commented Sep 27, 2026 •

Copy link
Copy Markdown

Review in Change Stack →

Navigate logical layers of code changes, visualize relationships, and explore their blast radius.

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Advanced

Run ID: 38204d95-0cc3-46c1-ab8a-ca056c49b9ab

📥 Commits

Reviewing files that changed from the base of the PR and between 6886d4a and 0184665.

⛔ Files ignored due to path filters (1)
  • docs/badge.svg is excluded by !**/*.svg
📒 Files selected for processing (1)
  • docs/getting-started.md

Included review availability: This review used your included allowance. Your plan provides up to 1 included review per hour; 0 remain after this review.


📝 Walkthrough

Walkthrough

The getting-started guide adds a “Show that you use it” section with a project badge and copyable Markdown and reStructuredText snippets.

Changes

Badge documentation

Layer / File(s) Summary
Add project badge snippets
docs/getting-started.md
The guide adds a README badge linked to the project site and provides equivalent Markdown and reStructuredText snippets.

Priority: ⬇️ Low

Estimated code review effort: 1 (Trivial) | ~3 minutes

Change: Feature

Merge Risk: ⚪ Minimal · up to 01846

The badge snippets resolve to the published badge. No merge blocker was identified; the change is ready for normal checks.

Architecture Summary

Architecture risk: 🔵 Low · up to 01846

The change affects 1 system.

Changed systems: docs

Architecture concerns
No architecture-level concerns identified.

Review details

Systems and components

  • observed — docs (service) was modified; 1 changed file maps to changed impact.

Before / after behavior

  • observed — Modified behavior in docs/getting-started.md: Adds a README badge linked to the project site and provides equivalent Markdown and reStructuredText snippets using the hosted badge image.
🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly and concisely describes the main change: hosting the README badge at commit-check.com/badge.svg. This matches the badge asset and documentation updates.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff. Analyzed 0 functions across 0…
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Commit to this branch
  • Create a new PR

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant