Skip to content

Commit 328eea0

Browse files
committed
Enhance documentation review instructions for clarity and detail, including PR handling and expanded review criteria
1 parent 703e6da commit 328eea0

File tree

1 file changed

+38
-6
lines changed

1 file changed

+38
-6
lines changed

.claude/commands/docs-review.md

Lines changed: 38 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -3,30 +3,62 @@ description: Review `pulumi/docs` changes for style, accuracy, and best practice
33
---
44

55
# Usage
6-
# Local: /docs-review
6+
# Local: /docs-review [pr-number]
77
# CI: Automatically runs on PRs
88

9-
Please review the code changes in this repository and provide feedback on style, accuracy, and best practices. Compare the current branch against the `master` branch (or review uncommitted changes if present).
9+
You will review documentation changes and provide feedback on style, accuracy, and best practices.
1010

11-
Provide your review as a single summary, highlighting any issues found and suggesting improvements.
11+
## For Local Usage: Determine Review Scope
12+
13+
**If a PR number is provided** ({{arg}}):
14+
- Use `gh pr view {{arg}}` to retrieve the PR title, description, and metadata
15+
- Use `gh pr diff {{arg}}` to get the full diff of changes
16+
- Review the PR changes according to the criteria below
17+
18+
**If no PR number is provided**:
19+
- Use `git status` to check for uncommitted changes
20+
- Use `git diff master` to compare current branch against master
21+
- If on master with uncommitted changes, review those changes
22+
- Review the changes according to the criteria below
23+
24+
## Review Criteria
1225

1326
Use the repository's CLAUDE.md, AGENTS.md, and STYLE-GUIDE.md for guidance on style and conventions.
1427

28+
Provide your review as a single summary, highlighting any issues found and suggesting improvements.
29+
1530
Be constructive and helpful in your feedback, but don't overdo the praise. Be concise.
1631

1732
Always provide relevant line numbers for any issues you identify.
1833

19-
**Pull Request Review Criteria**:
34+
**Criteria:**
2035

2136
- Always enforce `STYLE-GUIDE.md`. If not covered there, fall back to the [Google Developer Documentation Style Guide](https://developers.google.com/style).
2237
- Check **spelling and grammar** in all files.
23-
- Verify that **code examples run correctly** and follow established best practices. Do not suggest untested code.
2438
- Confirm that **all links resolve** and point to the correct targets (no 404s, no mislinked paths).
2539
- Validate that **content is accurate and current** (commands, APIs, terminology).
2640
- Ensure **all new files end with a newline**.
27-
- **If files are moved, renamed, or deleted**:
41+
- **Code examples** must run correctly and follow best practices:
42+
- Do not suggest untested code.
43+
- Examples should show realistic use cases, not contrived demos.
44+
- Examples should handle errors appropriately.
45+
- Examples should follow language-specific best practices.
46+
- **Files moved, renamed, or deleted**:
2847
- Confirm that moved or renamed files have appropriate aliases added to the frontmatter to avoid broken links.
2948
- Confirm that deleted files have a redirect created, if applicable.
49+
- **Images and assets**:
50+
- Check images have alt text for accessibility.
51+
- Verify image file sizes are reasonable.
52+
- Ensure images are in appropriate formats.
53+
- **Front matter**:
54+
- Verify required front matter fields (title, description, etc.).
55+
- Check meta descriptions are present and appropriate length.
56+
- **Cross-references and consistency**:
57+
- Check that related pages are cross-linked appropriately.
58+
- Verify terminology is consistent with other docs.
59+
- **SEO**:
60+
- Check that page titles and descriptions are SEO-friendly.
61+
- Verify URL structure follows conventions.
3062
- When reviewing **Documentation**: Serve the role of a professional technical writer. Review for:
3163
- Clarity and conciseness.
3264
- Logical flow and structure.

0 commit comments

Comments
 (0)