finish-work

GitHub

提交前质量检查清单,覆盖代码规范、类型检查、测试及文档同步。重点校验基础设施与跨层契约的可执行性,确保API、数据库变更完整,防止因规格抽象导致回归,保障代码提交前的完整性。

.agents/skills/finish-work/SKILL.md zhukunpenglinyutong/desktop-cc-gui

Trigger Scenarios

代码编写并测试完成后准备提交前 涉及基础设施或跨层契约修改时 最终审查 git commit 之前

Install

npx skills add zhukunpenglinyutong/desktop-cc-gui --skill finish-work -g -y
More Options

Non-standard path

npx skills add https://github.com/zhukunpenglinyutong/desktop-cc-gui/tree/main/.agents/skills/finish-work -g -y

Use without installing

npx skills use zhukunpenglinyutong/desktop-cc-gui@finish-work

指定 Agent (Claude Code)

npx skills add zhukunpenglinyutong/desktop-cc-gui --skill finish-work -a claude-code -g -y

安装 repo 全部 skill

npx skills add zhukunpenglinyutong/desktop-cc-gui --all -g -y

预览 repo 内 skill

npx skills add zhukunpenglinyutong/desktop-cc-gui --list

SKILL.md

Frontmatter
{
    "name": "finish-work",
    "description": "Pre-commit quality checklist covering lint, typecheck, tests, code-spec sync, API changes, database migrations, cross-layer verification, and manual testing. Blocks commit if infra or cross-layer specs lack executable depth. Use when code is written and tested but not yet committed, before submitting changes, or as a final review before git commit."
}

Finish Work - Pre-Commit Checklist

Before submitting or committing, use this checklist to ensure work completeness.

Timing: After code is written and tested, before commit


Checklist

1. Code Quality

# Must pass
npm run lint
npm run typecheck
npm run test
  • npm run lint passes with 0 errors?
  • npm run typecheck passes with no type errors?
  • Tests pass?
  • No console.log statements (use logger)?
  • No non-null assertions (the x! operator)?
  • No any types?

2. Code-Spec Sync

Code-Spec Docs:

  • Does .trellis/spec/backend/ need updates?
    • New patterns, new modules, new conventions
  • Does .trellis/spec/frontend/ need updates?
    • New components, new hooks, new patterns
  • Does .trellis/spec/guides/ need updates?
    • New cross-layer flows, lessons from bugs

Key Question:

"If I fixed a bug or discovered something non-obvious, should I document it so future me (or others) won't hit the same issue?"

If YES -> Update the relevant code-spec doc.

2.5. Code-Spec Hard Block (Infra/Cross-Layer)

If this change touches infra or cross-layer contracts, this is a blocking checklist:

  • Spec content is executable (real signatures/contracts), not principle-only text
  • Includes file path + command/API name + payload field names
  • Includes validation and error matrix
  • Includes Good/Base/Bad cases
  • Includes required tests and assertion points

Block Rule: If infra/cross-layer changed but the related spec is still abstract, do NOT finish. Run $update-spec manually first.

3. API Changes

If you modified API endpoints:

  • Input schema updated?
  • Output schema updated?
  • API documentation updated?
  • Client code updated to match?

4. Database Changes

If you modified database schema:

  • Migration file created?
  • Schema file updated?
  • Related queries updated?
  • Seed data updated (if applicable)?

5. Cross-Layer Verification

If the change spans multiple layers:

  • Data flows correctly through all layers?
  • Error handling works at each boundary?
  • Types are consistent across layers?
  • Loading states handled?

6. Manual Testing

  • Feature works in browser/app?
  • Edge cases tested?
  • Error states tested?
  • Works after page refresh?

Quick Check Flow

# 1. Code checks
npm run lint && npm run typecheck

# 2. View changes
git status
git diff --name-only

# 3. Based on changed files, check relevant items above

Common Oversights

Oversight Consequence Check
Code-spec docs not updated Others don't know the change Check .trellis/spec/
Spec text is abstract only Easy regressions in infra/cross-layer changes Require signature/contract/matrix/cases/tests
Migration not created Schema out of sync Check db/migrations/
Types not synced Runtime errors Check shared types
Tests not updated False confidence Run full test suite
Console.log left in Noisy production logs Search for console.log

Relationship to Other Commands

Development Flow:
  Write code -> Test -> $finish-work -> git commit -> $record-session
                          |                              |
                   Ensure completeness              Record progress
                   
Debug Flow:
  Hit bug -> Fix -> $break-loop -> Knowledge capture
                       |
                  Deep analysis
  • $finish-work - Check work completeness (this skill)
  • $record-session - Record session and commits
  • $break-loop - Deep analysis after debugging

Core Principle

Delivery includes not just code, but also documentation, verification, and knowledge capture.

Complete work = Code + Docs + Tests + Verification

Version History

  • cb4962a Current 2026-07-24 22:05

Same Skill Collection

.agents/skills/before-dev/SKILL.md
.agents/skills/brainstorm/SKILL.md
.agents/skills/break-loop/SKILL.md
.agents/skills/check-cross-layer/SKILL.md
.agents/skills/check/SKILL.md
.agents/skills/create-command/SKILL.md
.agents/skills/deploy-to-vercel/SKILL.md
.agents/skills/improve-ut/SKILL.md
.agents/skills/integrate-skill/SKILL.md
.agents/skills/onboard/SKILL.md
.agents/skills/record-session/SKILL.md
.agents/skills/start/SKILL.md
.agents/skills/update-spec/SKILL.md
.agents/skills/vercel-cli-with-tokens/SKILL.md
.agents/skills/vercel-composition-patterns/SKILL.md
.agents/skills/vercel-react-best-practices/SKILL.md
.agents/skills/vercel-react-native-skills/SKILL.md
.agents/skills/web-design-guidelines/SKILL.md
.agents/skills/writing-guidelines/SKILL.md
.codex/skills/parallel/SKILL.md
.agents/skills/coss/SKILL.md
.agents/skills/huashu-design/SKILL.md
.agents/skills/vercel-optimize/SKILL.md
.agents/skills/vercel-react-view-transitions/SKILL.md

Metadata

Files
0
Version
cb4962a
Hash
7034d410
Indexed
2026-07-24 22:05

inicio - Wiki
Copyright © 2011-2026 iteam. Current version is 2.155.2. UTC+08:00, 2026-08-20 00:07
浙ICP备14020137号-1 $mapa de visitantes$