reviewing-prs

General workflow for fetching, inspecting, reviewing GitHub Pull Requests using the gh CLI, drafting user-aligned review comments, and securing approval before…

npx skills add https://github.com/flutter/devtools --skill reviewing-prs

Reviewing Pull Requests

This skill outlines the workflow for inspecting GitHub Pull Requests using the gh CLI, drafting review feedback, and securing user approval before posting review comments.

Approval Safeguard (Strict Requirement)

[!IMPORTANT] NEVER post comments or reviews to GitHub without explicit prior user approval. Always present draft review comments to the user in natural language first. Only execute write commands (gh pr comment, gh pr review) after the user approves.

Workflow

1. Request Information via GitHub CLI

  • PR Details:
    gh pr view <pr-number> --repo <owner/repo> --json title,body,author,state,headRefName,baseRefName,comments,reviews,files
    
  • Code Diff:
    gh pr diff <pr-number> --repo <owner/repo>
    
  • Existing Inline Comments:
    gh api repos/<owner/repo>/pulls/<pr-number>/comments
    
  • CI / Status Checks:
    gh pr checks <pr-number> --repo <owner/repo>
    

2. Inspect Context & Prior Feedback

  • Read the PR description, linked issues, and full diff.
  • Verify whether existing bot or human comments have already been addressed in subsequent commits.

3. Draft Review Comments

  • Keep comments direct, concise, and focused on code quality and correctness.
  • Approvals: Keep comments concise (LGTM or A couple comments but lgtm.). Avoid fluffy praise or re-summarizing the PR.
  • Actionable Feedback: Reference specific files, line numbers, and rationale when leaving suggestions.

4. Present Draft & Post Only Upon User Approval

[!IMPORTANT] NEVER post comments or reviews to GitHub without explicit prior user approval.

  1. Present the drafted review comments to the user in your response window.
  2. Ask for confirmation: "Would you like me to submit this review to GitHub?"
  3. Once explicitly approved by the user, post the review:
    gh pr review <pr-number> --repo <owner/repo> --comment --body "<approved review text>"
    

More skills from flutter

dart-modern-features
flutter
To find candidates for modernization:
flutter-fix-layout-issues
flutter
Fixes Flutter layout errors (overflows, unbounded constraints) using Dart and Flutter MCP tools. Use when addressing "RenderFlex overflowed", "Vertical…
adding-release-notes
flutter
Adds user-facing change descriptions to DevTools release notes. Use when documenting improvements, fixes, or new features in the NEXT_RELEASE_NOTES.md file.
reviewing-devtools-prs
flutter
DevTools repository-specific PR review workflow enforcing DevTools style guidelines and common review patterns. Use when reviewing pull requests in the…
dart-use-primary-constructors
flutter
Help users write syntactically and semantically correct primary constructors in Dart, and migrate/use the new constructor syntax, empty-body semicolon syntax,…
code-documentation
flutter
Guide for writing effective code documentation, including docstrings, JSDoc, dartdoc, and implementation comments. Use this skill when writing new code, adding…
api-review
flutter
Reviews the specified code against the canonical API Design guidelines. Use this skill when the user asks for an API review or to check code against API design…
flutter-accessibility
flutter
Implement WCAG 2 and EN 301 549 accessibility standards and adaptive layouts in Flutter apps. Enforces semantic annotations, tap target sizes (48x48 dp minimum), and text contrast ratios (4.5:1 for small text, 3:1 for large) across mobile, web, and desktop platforms Provides decision logic for web semantics initialization, interactive widget wrapping, screen-size-based layout switching, and keyboard/mouse input handling Includes focus traversal management via FocusTraversalGroup and...