本文へ移動
cccskills
無料GitHub で公開

review-pr-comments

Review and resolve PR review comments on the current branch's PR in this Flutter repository, from both AI reviewers (CodeRabbit, CodiumAI, CodePilot, Copilot, etc.) and human reviewers. Fetches comments via `gh`, splits them into AI and human groups, verifies each comment against the actual Flutter code, triages them, proposes fixes, and optionally applies fixes, replies to comments, and pushes. Use when the user asks to review PR comments, resolve PR feedback, review AI comments, review human review comments, or handle code review feedback.

インストール方法を見る

含まれるファイル(1)

  • SKILL.md9.4 KB

SKILL.md(原文)

インストールする前に、エージェントに与えられる指示の中身を確認できます。

Flutter Template Review PR Comments

Handle review feedback on the current PR from both automated AI reviewers and human reviewers. Results are always presented split into AI and Human sections so the user can read them separately.

Read First

  • AGENTS.md
  • docs/PROJECT_OVERVIEW.md
  • docs/PROJECT_GUIDELINES.md
  • the files referenced by PR comments
  • nearby source files when a comment depends on local context

Preconditions

  • The GitHub CLI gh must be installed and authenticated.
  • The current branch must have an open PR.
  • Do not apply fixes, reply to comments, commit, or push until the user approves those actions.

Step 1: Find the PR

gh pr list --head "$(git branch --show-current)" --json number,url --jq '.[0]'

If no PR is found, inform the user and stop. If gh is not available or not authenticated, report the blocker and the command that failed.

Step 2: Fetch All Review Comments

Extract the PR number and owner/repo:

number="$(gh pr list --head "$(git branch --show-current)" --json number --jq '.[0].number')"
repo="$(gh repo view --json nameWithOwner --jq '.nameWithOwner')"

Fetch all PR review comments, including inline comments on code:

gh api "repos/$repo/pulls/$number/comments" --paginate \
  --jq '.[] | {id: .id, user: .user.login, user_type: .user.type, path: .path, line: .line, original_line: .original_line, diff_hunk: .diff_hunk, body: .body}'

Also fetch top-level issue-style comments on the PR (some reviewers use these):

gh api "repos/$repo/issues/$number/comments" --paginate \
  --jq '.[] | {id: .id, user: .user.login, user_type: .user.type, body: .body}'

Optionally fetch the PR review summaries if the user asks for every review artifact:

gh api "repos/$repo/pulls/$number/reviews" --paginate \
  --jq '.[] | {id: .id, user: .user.login, user_type: .user.type, state: .state, body: .body}'

Step 3: Classify Each Comment — AI vs Human

Split every comment into one of two buckets:

  • AI — the author login matches a known bot pattern (case-insensitive): coderabbit, codiumai, codepilot, copilot, sonarcloud, deepsource, sourcery OR the GitHub user.type is Bot.
  • Human — everything else.

Group comments by reviewer within each bucket (so the user sees "CodeRabbit: 3", "Alice: 2", etc).

If both buckets are empty, inform the user and stop.

Step 4: Triage Each Comment

For each comment (in both buckets):

  1. Read the referenced file and line range to understand the actual code.
  2. Read surrounding Flutter template context when needed, especially providers, use cases, route registration, DTO/entity mapping, localization, and generated source inputs.
  3. Determine if the issue described actually exists in the current branch.
  4. Classify as one of:
    • Must-Fix: compile/analyze errors, runtime crashes, broken navigation, data loss, security issues, secrets exposure, invalid generated-code assumptions, or release/build breakage.
    • Should-Fix: real bugs, incorrect Riverpod lifecycle handling, bad async/ref usage, DTO/entity mapping mistakes, localization/assets/codegen issues, test failures, or logic errors that affect correctness.
    • Nice-to-Have: valid but low-impact suggestions such as naming, readability, small UI polish, or minor refactors that are not required for correctness.
    • Irrelevant: false positive, already handled, obsolete/outdated diff context, generated file comment where the source is correct, or not applicable to this Flutter template.

Human comments deserve more deference than AI comments. If a human raised a concern you do not fully understand, surface it to the user rather than classifying it as Irrelevant.

When comments mention source-platform concepts from KMP, Android, or iOS migration work, translate the concern into Flutter terms before deciding. For example, check the destination feature state, use case, route, or widget behavior rather than preserving Kotlin/Swift architecture literally.

Flutter-Specific Checks

Use these checks when comments touch related code:

  • Feature files should follow the repo pattern: *_page.dart, *_page_content.dart, *_state.dart, and *_event.dart when state/events are needed.
  • Route widgets should use @RoutePage() and be registered in lib/app/navigation/app_router.dart; generated route files should not be hand-edited.
  • Riverpod notifiers should keep IO in use cases, guard page-scoped async follow-up with ref.mounted, and use keepAlive only for app-scoped state or deliberate async lifetimes.
  • DTOs belong in lib/common/data/dto/, entities in lib/common/data/entity/, and UI should not consume transport models directly.
  • Shared UI should prefer lib/common/component/, lib/common/composition/, context.colorScheme, context.textTheme, and context.locale.
  • Localization changes belong in assets/localization/*.arb and require generated accessors under lib/assets/.
  • Generated files such as *.g.dart, *.freezed.dart, *.gr.dart, and lib/assets/** should be fixed through their source inputs and make gen.
  • Firebase, notifications, Remote Config, and startup comments must be checked against lib/app/setup/setup_app.dart because some template hooks are scaffolded or disabled.
  • Secrets and decrypted environment files should not be modified unless the review comment is explicitly about secrets setup.

Step 5: Present Findings (Split by AI / Human)

Present results in two clearly labeled sections. Within each, group by severity.

### AI Reviewer Comments
Reviewers: CodeRabbit (3), Copilot (1)

#### Must-Fix
...

#### Should-Fix
...

#### Nice-to-Have
...

#### Irrelevant
...

---

### Human Reviewer Comments
Reviewers: @alice (2), @bob (1)

#### Must-Fix
...

#### Should-Fix
...

#### Nice-to-Have
...

#### Irrelevant
...

Each row or bullet includes:

  • comment id or stable number from the fetched list
  • reviewer login
  • file and line when available
  • issue summary
  • classification
  • proposed fix for relevant comments
  • reason when classified as Irrelevant

Wait for user confirmation before applying any fixes. The user may respond with per-comment decisions:

  • fix: apply the proposed fix
  • skip: leave as-is, no reply needed unless the user asks
  • defer: reply with a short explanation of why it is deferred
  • reply: answer the comment without code changes
  • ignore: for AI comments only; use the reviewer-specific ignore command only when supported, such as @coderabbitai ignore for CodeRabbit

Do not use AI ignore commands for human comments.

Step 6: Apply Fixes (After User Approval)

  1. Make only the code changes approved by the user.
  2. Keep changes scoped to the commented files and the directly required source inputs.
  3. If a generated file would need edits, change the annotated/source file and run make gen.
  4. Verify the relevant Flutter checks:
    • run make gen when annotations, routes, DTOs, localization, or assets changed
    • run fvm flutter analyze
    • run fvm flutter test when behavior, widgets, state, use cases, or tests changed
    • run make integration_test only when Patrol integration flows changed or the user asks for it
  5. Commit changes only if the user explicitly approved a commit.
  6. Reply to each comment on the PR based on the user's decision:
    • Fixed comments: brief description of what was done.
    • Deferred comments: explanation of why.
    • Irrelevant / not applicable comments: explanation of why it is not applicable.
    • Ignored AI comments: reviewer-specific ignore command when supported.

For inline PR review comments, reply with:

gh api "repos/$repo/pulls/$number/comments/$comment_id/replies" \
  -f body="<reply message>"

For top-level issue comments or review summaries, use a normal PR comment when a direct reply endpoint is not available:

gh pr comment "$number" --body "<reply message>"
  1. Push changes only if the user explicitly approved a push.

Rules

  • Always verify comments against the actual code before accepting them.
  • Never blindly apply AI-suggested fixes; they may be wrong or incomplete.
  • Give human reviewers' concerns more weight. When uncertain, ask the user rather than dismissing.
  • Present findings split by AI / Human before making any changes.
  • Do not edit generated files directly. Fix the source and regenerate.
  • Do not touch files outside the approved PR-comment scope unless necessary for the approved fix.
  • Do not stage, commit, push, or reply to PR comments without user approval.
  • Do not preserve KMP, Android, or iOS architecture terms in Flutter code unless the Flutter project already has the equivalent abstraction.
  • Leave clear notes for comments that cannot be resolved mechanically or require product/design judgment.

レビュー

まだレビューはありません。使ってみた感想をお寄せください。

同じリポジトリのスキル

概要と使いどころ

Build/test/lint verification pass for this Flutter app — runs codegen, analyze, test, then iOS + Android native builds in parallel, then `dart format`. Does NOT commit anything; leaves the working tree dirty so the user can review and commit on demand. Used at the end of the prd → techspec → tasks → implement-tasks-sequence flow before `pr-review`, and can also be invoked manually when the user says "verify build", "run full verification", or "check everything".

日本語の概要は準備中です。原文の説明を表示しています。

strvcom/flutter-template242026年6月18日 更新

create-pr

無料

Create or update a GitHub PR for this Flutter repository using gh CLI. Verifies the work with build-verify and pr-review, generates an inline PR description, commits pending changes when approved, pushes, and opens or updates the PR. Supports stacked PRs by asking for the base branch when detection is ambiguous. Use when the user says "create PR", "open PR", "push PR", or wants to submit their work for review.

日本語の概要は準備中です。原文の説明を表示しています。

strvcom/flutter-template242026年6月18日 更新

Build a full feature in this Flutter repository that includes backend or storage data flow: read API schema, create DTOs, map DTOs to entities, add Riverpod use cases, connect feature state, and render UI data. Use when a task goes beyond a screen and needs real data integration.

日本語の概要は準備中です。原文の説明を表示しています。

strvcom/flutter-template242026年6月18日 更新

Create a new Flutter screen in this repository using the existing feature structure, AutoRoute setup, Riverpod state pattern, and code generation workflow. Use when adding a new page, route, stateful screen, or feature folder in this template.

日本語の概要は準備中です。原文の説明を表示しています。

strvcom/flutter-template242026年6月18日 更新

implement

無料

Implement a single Flutter task following this repository's Riverpod, Freezed, AutoRoute, DTO/entity, codegen, and verification conventions. Reads the task definition, PRD, and tech spec, then executes the implementation. When invoked standalone, verifies the change; when invoked by implement-tasks-sequence, writes code only and leaves verification to start-job/build-verify. Use when the user says "implement task X", "work on task X", or wants to execute a specific task from the task list.

日本語の概要は準備中です。原文の説明を表示しています。

strvcom/flutter-template242026年6月18日 更新

Orchestrates implementation of all tasks for a feature using an agent team. Respects task dependencies, runs tasks in correct order, parallelizes independent tasks. Does NOT build, run tests, or commit at any point — verification is delegated to the caller (typically `/start-job`, which runs `build-verify` and `pr-review uncommitted` afterwards). Use when the user says "implement all tasks", "run the task sequence", "implement the feature", or wants to execute multiple tasks from a task list end-to-end.

日本語の概要は準備中です。原文の説明を表示しています。

strvcom/flutter-template242026年6月18日 更新

strvcom のスキルをすべて見る

このスキルの問題を報告する