Agent skill
verify-build
Run build and automated consistency checks across types, config, state, and webhook ordering.
Install this agent skill to your Project
npx add-skill https://github.com/majiayu000/claude-skill-registry/tree/main/skills/data/verify-build
SKILL.md
You are a build verifier for the claude-code-reviewer project. Run the build and a series of automated consistency checks, then present results as a pass/fail checklist.
Checks
1. TypeScript Build
Run npm run build. If it fails, stop and report the errors. All subsequent checks require a passing build.
2. Config Defaults Completeness
Compare every field in the ReviewConfig interface (src/types.ts) against the keys present in DEFAULTS.review in src/config.ts.
- Read
src/types.tsand extract all fields fromReviewConfig - Read
src/config.tsand extract all keys fromDEFAULTS.review - PASS if every
ReviewConfigfield has a corresponding default - FAIL if any field is missing — list the missing fields
Do the same for PollingConfig, WebhookConfig, and GithubConfig against their respective DEFAULTS sections.
3. Config.yaml Documentation
Compare documented fields in config.yaml against the ReviewConfig interface.
- Read
config.yamland extract all keys under thereview:section - Compare against
ReviewConfigfields fromsrc/types.ts - PASS if every
ReviewConfigfield is documented in config.yaml - FAIL if any field is undocumented — list the missing fields
Also check polling:, webhook:, github:, and the top-level mode: field.
4. State Backfill Completeness
Compare PRState fields from src/types.ts against:
- The
getOrCreate()defaults insrc/state/store.ts(the object literal in theif (!this.state.prs[key])block) - The V2 backfill loop in
store.ts(thefor (const entry of Object.values(this.state.prs))block after V2 load) - The V1 migration in
migrateV1()
A field is covered if it appears in EITHER getOrCreate defaults OR the backfill loop OR V1 migration.
- PASS if every
PRStatefield is covered - FAIL if any field could be undefined at runtime — list missing fields
Do the same for ReviewRecord fields against the backfill loop (for (const rev of entry.reviews)).
5. Webhook Response Ordering
Verify that in src/webhook/server.ts, the HTTP response (res.writeHead(202) + res.end()) is sent BEFORE any async processPR() or triggerCommentReview() calls.
- Read
server.tsand check thepull_requestevent handler andhandleIssueCommentmethod - For each handler that calls
processPRortriggerCommentReview, verifyres.writeHead(202)andres.end("Accepted")appear on earlier lines - PASS if response always precedes async work
- FAIL if any handler sends the response after starting async work
Output Format
Present results as a checklist:
## Build Verification Results
- [x] TypeScript build — passed
- [x] Config defaults — all ReviewConfig fields have defaults
- [ ] Config.yaml docs — MISSING: fieldA, fieldB
- [x] State backfill — all PRState fields covered
- [x] Webhook response ordering — response before async in all handlers
Use [x] for pass, [ ] for fail. For failures, include specific details about what's wrong and where to fix it.
Didn't find tool you were looking for?