What problem does it solve?
This skill automates posting a targeted review comment to a GitHub pull request, eliminating repetitive manual commenting during code reviews.
Core Features & Use Cases
- Post a review comment on a specific file line in a PR using the GitHub CLI.
- Support single-line and multi-line comments with control over line numbers and sides.
- Useful for automated feedback during code reviews, CI checks, or bot-driven PR guidance.
Quick Start
Use the add-review-comment skill to post a comment on a PR. Example commands:
gh api repos/<owner>/<repo>/pulls/<pr_number>/comments
-f body="This is an automated comment 🤖 Generated with Claude"
-f path=<file_path>
-F line=<line_number>
-f side=RIGHT
-f commit_id="$(gh pr view <pr_number> --repo <owner>/<repo> --json headRefOid -q .headRefOid)"
--jq '.html_url'
Single-line or multi-line use variants can be constructed by adjusting body, start_line, end_line, and line fields as needed.