Skip to content

docs: lead the README with what a pull request sees - #545

Closed
shenxianpeng wants to merge 3 commits into
mainfrom
docs/first-screen
Closed

docs: lead the README with what a pull request sees#545
shenxianpeng wants to merge 3 commits into
mainfrom
docs/first-screen

Conversation

@shenxianpeng

@shenxianpeng shenxianpeng commented Aug 12, 2026

Copy link
Copy Markdown
Member

The first screen of the README was a table of contents and an overview paragraph; the thing that actually sells the tool — the PR report — was nowhere on the page. Now it opens with:

  1. The value proposition in one line: one versioned policy, enforced in the terminal, in hooks, in CI, and on AI agents.
  2. The PR comment as the hero image (light and dark variants via <picture>, so it matches the viewer's GitHub theme): a failure report with the offending values and each failed rule linked to its documentation, exactly as commit-check-action renders it today.
  3. A complete, copy-pasteable GitHub Actions workflow in the quick start — the previous quick start covered CLI, pre-commit and the badge, but not the integration most decision-makers land here for. Includes the pull-requests: write permission that pr-comments needs, the author checks, and a note on fork PRs. The stale rev: v2.12.2 pin catches up to v2.14.0.

The table of contents moves below the quick start instead of being the first thing on the page, and the CLI demo gif moves down to the examples section it illustrates — the terminal view is a detail; the PR view is the pitch.

Asset files: assets/pr-comment-light.png / assets/pr-comment-dark.png, rendered to match the report layout the action actually posts.

The first screen was a table of contents and a paragraph; the thing
that sells the tool — the PR report with every commit, the title, the
branch and the author checked against the project's own policy — was
nowhere on the page. Now it opens with the value proposition, the PR
comment (light and dark), and a four-step quick start that finally
includes the GitHub Action. The table of contents moves below the
quick start, the stale v2.12.2 pin catches up to v2.14.0, and the CLI
demo gif moves to the examples section it illustrates.
@shenxianpeng
shenxianpeng requested a review from a team as a code owner August 12, 2026 09:26
@github-actions github-actions Bot added the documentation Improvements or additions to documentation label Aug 12, 2026
@coderabbitai

coderabbitai Bot commented Aug 12, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

📝 Walkthrough

Walkthrough

The README now presents Commit Check as a versioned policy across terminal, hooks, CI, and AI agents. It updates Quick Start instructions, adds GitHub Actions configuration, removes an obsolete contents entry, and adds a terminal demo.

Changes

README documentation

Layer / File(s) Summary
Policy positioning and examples
README.md
The introduction describes unified policy enforcement and adds pull-request comment imagery. The Examples section adds a terminal demo GIF. The Table of Contents removes the Overview entry.
Quick Start integrations
README.md
The Quick Start updates the pre-commit revision to v2.14.0 and adds GitHub Actions checks for messages, branches, pull-request titles, job summaries, and conditional pull-request comments.

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

Possibly related PRs

Suggested reviewers: sahilsaiyed-oss

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
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.
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly describes the main README change: leading with the pull request view and report.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch docs/first-screen

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.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 2

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@README.md`:
- Around line 47-57: Update the README section around the commit-check example
to show a complete valid GitHub Actions workflow, including name, trigger,
permissions with pull-requests write, jobs, runner, checkout, and the
commit-check action step; alternatively label the snippet explicitly as
jobs.<job>.steps. Document that pr-comments is skipped for fork pull requests.
- Around line 50-56: Update the commit-check action example to enable author
validation by adding the author-name and author-email inputs alongside the
existing checks. Clarify the pull-request scope in the README to state that the
action validates one resolved author rather than every commit author in the pull
request.
🪄 Autofix

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro Plus

Run ID: 566d8898-e6e3-47db-bbc5-7ac8c8c27aa9

📥 Commits

Reviewing files that changed from the base of the PR and between 423916a and fc437e6.

⛔ Files ignored due to path filters (2)
  • assets/pr-comment-dark.png is excluded by !**/*.png
  • assets/pr-comment-light.png is excluded by !**/*.png
📒 Files selected for processing (1)
  • README.md

Comment thread README.md
Comment thread README.md Outdated
A bare steps fragment is invalid as a workflow file and silently lacks
the pull-requests permission pr-comments needs. The snippet is now a
whole workflow, enables the author checks the screenshot shows, and
says what happens on fork PRs and whose author is validated.
The screenshot showed a redesigned all-scope table that was reverted
before shipping; the image and its caption now show the real report —
a failures-only table with everything that passed folded away.
@sonarqubecloud

Copy link
Copy Markdown

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

Labels

documentation Improvements or additions to documentation

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant