Skip to content
Back to skills

Wrap Up

ASecurity

Post-implementation quality gate. Runs automated checks (tests, lint, types), invokes /flagrare:implementation-review for the nine-check parallel review, culls every code comment in the diff that is not a trap-preventer, then performs additional SOLID and Clean Code review on any findings not covered. Use when the user says 'wrap up', 'review changes', 'check my work', 'am I done', or after completing an implementation task.

  • 15 stars
  • 0 votes
  • 0 copies
  • 3 views
  • Added May 26, 2026
developmentpythongokotlinbashsqlnodetestinggitsecurity

Security analysis

A100/100

Scanned December 5, 2026

npx -y skills add Flagrare/agent-skills --skill wrap-up --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Wrap Up?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Wrap Up
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/flagrare-wrap-up/badge)](https://www.skillsdirectory.com/skills/flagrare-wrap-up)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: wrap-up
description: "Post-implementation quality gate. Runs automated checks (tests, lint, types), invokes /flagrare:implementation-review for the nine-check parallel review, culls every code comment in the diff that is not a trap-preventer, then performs additional SOLID and Clean Code review on any findings not covered. Use when the user says 'wrap up', 'review changes', 'check my work', 'am I done', or after completing an implementation task."
---

# Wrap-up

Validate implementation quality through automated checks and structured review.

This skill orchestrates automated tooling and the `/flagrare:implementation-review` skill, then layers additional quality checks on top.

---

## When to Use

1. User says "wrap up", "review changes", "check my work", "am I done", "did I miss anything"
2. After completing a todo item or implementation task
3. Before committing (remind the user: "Ready for wrap-up?")

---

## Workflow

### Step 1: Run Automated Checks

Detect and run the project's test, lint, and typecheck commands.

**Detection order:**

1. Check `package.json` for scripts
2. Check `build.gradle.kts` / `build.gradle` for tasks
3. Check `pyproject.toml` for tool configs
4. Check `Makefile` for targets
5. Check common config files (`.eslintrc`, `tsconfig.json`, `pytest.ini`, etc.)

**Common commands by stack:**

| Stack | Test | Lint | Typecheck |
|-------|------|------|-----------|
| Node (npm) | `npm test` | `npm run lint` | `npm run typecheck` or `npx tsc --noEmit` |
| Node (pnpm) | `pnpm test` | `pnpm lint` | `pnpm typecheck` |
| Kotlin/Gradle | `./gradlew test` | `./gradlew ktlintCheck` | (built into compiler) |
| Python | `pytest` | `ruff check .` or `flake8` | `mypy .` or `pyright` |
| Go | `go test ./...` | `golangci-lint run` | (built into compiler) |

**Execute all three, continue even if one fails:**

```bash
{test_cmd} ; {lint_cmd} ; {typecheck_cmd}
```

**Report failures clearly:**

```
## Automated Checks

| Check | Status | Issues |
|-------|--------|--------|
| Tests | PASS | - |
| Lint | FAIL | 3 errors in `src/utils.ts` |
| Types | PASS | - |
```

If any check fails, list the specific errors.

### Step 2: Invoke `/flagrare:implementation-review`

Call `/flagrare:implementation-review`. This runs nine parallel subagent checks:

1. Plan gap analysis
2. Use-case coverage
3. Missing test scenarios
4. Test philosophy (Kent Dodds Testing Trophy)
5. SOLID violations
6. Clean Code violations
7. Security (pulls in `/flagrare:security-audit`, and traces every id the caller sends to its ownership check)
8. Independent walk (an agent that never sees the plan walks the flow)
9. Falsified tests (break the covered code, confirm each test fails)

Checks 2-4 apply `/flagrare:testing-philosophy`, behavior over implementation and the e2e necessity floor, so test quality is owned there; don't re-litigate it in Step 4. Check 7 applies `/flagrare:security-audit`, so security is owned there; don't re-litigate it in Step 4 either.

**Wait for it to complete.** Collect all findings.

### Step 2.5: Run the repo's own skills and review rules

The generic checks above don't know what this repo's reviewers enforce. Every run, look for the repo's own rules and run the ones that apply to the diff:

1. **Skills that live in the repo**: `.claude/skills/*/SKILL.md` and similar agent folders at the repo root. Read each description. Run every one whose trigger matches the diff, for example a query-plan check for a changed SQL query or a migration check for a new migration. A skill that arrived with a recent pull may not be loaded in the session yet. In that case, read its `SKILL.md` and follow it step by step.
2. **The user's review skills for this repo**: skills in the session's skill list, or in `~/.claude/skills/`, whose name or description names this repo (`<repo>-review` and similar). Run them on the diff. A review skill for a sibling repo doesn't apply. Name it and say why you skipped it.
3. **Written rules**: `AGENTS.md`, `CLAUDE.md`, `CONTRIBUTING.md`, development guidelines and review checklists in the repo. Check the diff against their red flags.

Fold the findings into Step 5 like any other review finding. When the repo has none of these, say "none found" in the report rather than skipping the step silently.

Field-tested the hard way: a fix that changed a SQL join reached the pull request stage without the repo's own query-plan skill, which had landed on main that morning. The user had to ask whether the repo's review skill had run.

### Step 3: Comment cull

Every code comment the diff adds is deleted unless it is a trap-preventer. This step acts; it does not flag. Check 6 of `/flagrare:implementation-review` reports what-comments, this step is where the deleting happens, and it covers every comment in the diff, not only the ones Check 6 named.

Enumerate every comment in the diff: line comments, block comments, file headers, doc comments on non-public symbols, and comments in test files, which are the most common survivors. Apply this test to each one, and both halves must hold:

1. If a future reader deleted or moved the code this comment sits on, would that look like a safe cleanup?
2. Would it break something they could not see from the code, the types, or the tests?

A "no" to either half means delete. The reader is not confused without it; they are only less entertained.

Before keeping a survivor, try to make it unnecessary. A constraint that can live in a name, a test title, or an assertion message should live there instead, because those are read every time the code is, and the comment is read once. A test that must be the first render in a fresh module registry is named for that; a fixture id that has a recovery query belongs in the assertion message that fires when the fixture is gone, not in a header the reader scrolls past.

What always goes, whatever it says about itself:

- **What-comments**: restate the code below them.
- **Provenance**: "on purpose", "deliberately", "the design says", "per the ticket", "the reviewer asked". These record why the author did something, which is a fact about the author, not a constraint on the reader.
- **File headers**: "this file holds the ids the specs use", "shared helpers for X". The file name and the exports say this.
- **Citations**: tickets, TDDs, Figma frames, PR numbers, doc sections. They rot, and the reader cannot act on them.
- **Narration in tests**: "we render, then we assert". The test body is the narration.

Never trim a comment into survival. Delete it whole or keep it whole; a comment that needed shortening was not a trap-preventer, it was a long provenance note. A survivor is one or two lines, states the constraint plainly, and cites nothing.

Apply the deletions directly, without asking. Record every deletion and every survivor with its one-line justification for the Step 5 report, so the user can veto a deletion or cut a survivor. The bias is that a human reviewer will ask "does this file need all these comments?" far more often than "why is there no comment here."

### Step 4: Additional Review (gaps not covered by /flagrare:implementation-review)

After `/flagrare:implementation-review` reports, check for anything it might have missed due to scope. These are supplementary checks, not duplicates.

**Naming review:**
- Are names intention-revealing?
- Do they avoid mental mapping?
- Bad: `d`, `theList`, `hp`, `apts`
- Good: `elapsedDays`, `activeUsers`, `hoursPerTask`, `apartments`

**Function size review:**
- Are functions small (ideally under 20 lines)?
- Do they have few arguments (3 or fewer ideal)?
- Are abstraction levels consistent within a function?

**Error handling review:**
- Are exceptions used instead of error codes?
- Is error handling separated from business logic?
- Are error messages informative?

**Code smells not covered by SOLID:**
- Duplicate code across the diff
- Feature envy (method uses another object's data excessively)
- Data clumps (groups of data that always appear together)
- Primitive obsession (using primitives instead of small objects)
- Long parameter lists without grouping

### Step 5: Generate Combined Report

Merge automated check results, `/flagrare:implementation-review` findings, and supplementary review into one report:

```
## Wrap-up Report

### Automated Checks
| Check | Status |
|-------|--------|
| Tests | PASS/FAIL |
| Lint | PASS/FAIL |
| Types | PASS/FAIL |

### Implementation Review (from /flagrare:implementation-review)
[Paste the nine-check summary verbatim]

### Repo rules
- Ran: {skill or rules file}, {result}
- Not applicable: {skill}, {why}
- (or: none found)

### Comment cull
- Deleted: `{file}:{line}` "{first words of the comment}"
- Kept: `{file}:{line}` "{first words}", {the invisible break it prevents}

### Supplementary Review

#### Good
- {aspect}: {what's done well}

#### Suggestions
- **{aspect}** in `{file}:{line}`: {issue}
  - Suggestion: {how to fix}

### Summary
- {N} blocking issues (must fix)
- {M} suggestions (should consider)
- Ticket: {KEY} is {status}
- Overall: Ready to commit / Needs attention
```

**Ticket line.** If the branch name or commits carry a ticket key, read its status. Code exists, so the work has started: if the ticket is still before `started` (To Do, Backlog), move it now, following `<plugin root>/lib/tickets/LIFECYCLE.md` (the plugin root is two directories above this skill's base directory). Anything at or past `started` stays as it is; `/flagrare:open-pr` moves it to review.

### Step 6: Offer Fixes

If issues were found, **close with a tool, not prose.** The Step 5 report is a large artifact; ending with a prose "Would you like me to…" frequently reads as turn-complete and stops before the user can answer (the stall pattern in [`docs/research/2026-06-11-claude-code-goal-anti-stall.md`](../../../../docs/research/2026-06-11-claude-code-goal-anti-stall.md)). Immediately after the report, issue an `AskUserQuestion` tool call.

**The question names every finding.** The question dialog can cover the report, so it may be the only thing the user sees when they decide. Never offer a generic menu like "Apply the review suggestions" or "Fix the lint errors". Build it like this:

- Use `multiSelect: true` with **one option per finding**. The **label** is the fix in a few words, naming where it goes ("Test the discount error on a deleted account"). The **description** says what's wrong, in plain words, and what happens if it stays: "Nothing checks that a bad discount code still gets the discount error when the account is also gone, so reordering the lookup could break it silently."
- Check failures (lint, types, tests) are findings too: one option each, naming the file and the error, never "fix the automated check errors".
- The question line says how many findings there are and which change they're about ("2 test gaps in the checkout change: which should I fix?").
- More than 4 findings: split them across up to 4 questions by kind (check failures, test gaps, code), 4 options each. If there are still more, fold the smallest ones into one option whose description lists each one.
- Picking nothing means skip. Don't add a "Skip" option that takes a slot from a finding.

Comment deletions are not on this menu: Step 3 already applied them. If the user wants one back, they say so after reading the report.

Do not render these as a numbered prose list and wait, use the tool so the user gets buttons and the turn doesn't end ambiguously. Field-tested the hard way: the menu read "Fix the automated check errors / Apply the review suggestions / Both / Skip", and the user said that nearly every time, the skill asked whether to address the findings without saying what they were.

---

## Anti-patterns

- Don't skip automated checks. They catch things review cannot.
- Don't duplicate what `/flagrare:implementation-review` already covers. If it reported on SOLID, don't re-report the same finding.
- Don't block on advisory findings. Use judgment on what's blocking vs nice-to-have.
- Don't skip this because "the change is small". Small changes still break things.
- Don't stop at the generic checks. A repo that ships its own skills or review rules expects them to run, and the user shouldn't have to ask.
- Don't keep a comment because it is a "why". Most whys are provenance. The only why that survives is the one whose absence lets a reader break something they cannot see.
- Don't ask "apply the suggestions?" without naming them. Each finding is its own option, with what's wrong and the fix, because the question dialog may be all the user sees.
- Don't leave comment deletions for the reviewer to request. "Does this file need all these comments?" on a PR means Step 3 was skipped.

---

## Flow position

```
[code changes complete]
     |
     v
/flagrare:wrap-up
     |--- Step 1: automated checks (tests, lint, types)
     |--- Step 2: /flagrare:implementation-review (9 parallel subagents)
     |--- Step 2.5: the repo's own skills and review rules
     |--- Step 3: comment cull (delete by default)
     |--- Step 4: supplementary review
     |--- Step 5: combined report
     |
     v
git commit
     |
     v
/flagrare:release-check
```

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

View all in development →

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.