workflow
Compare original and translation side by side
🇺🇸
Original
English🇨🇳
Translation
ChineseDevelopment Workflow Orchestrator
开发工作流编排器
Guides the complete development cycle: Ticket → Planning → Coding → Review → PR.
指导完整的开发周期:工单 → 规划 → 编码 → 评审 → PR。
Workflow Overview
工作流概述
┌─────────────────────────────────────────────────────────────┐
│ DEVELOPMENT WORKFLOW │
├─────────────────────────────────────────────────────────────┤
│ 1. INITIATE │
│ └── Select ticket → Clone repo → Create worktree │
├─────────────────────────────────────────────────────────────┤
│ 2. PLAN │
│ └── Understand requirements → Create implementation plan │
├─────────────────────────────────────────────────────────────┤
│ 3. CODE │
│ └── Implement → Test → Iterate │
├─────────────────────────────────────────────────────────────┤
│ 4. REVIEW │
│ └── Self-review → Fix issues → Validate │
├─────────────────────────────────────────────────────────────┤
│ 5. SHIP │
│ └── Create PR → Update ticket → Clean up worktree │
└─────────────────────────────────────────────────────────────┘┌─────────────────────────────────────────────────────────────┐
│ DEVELOPMENT WORKFLOW │
├─────────────────────────────────────────────────────────────┤
│ 1. INITIATE │
│ └── Select ticket → Clone repo → Create worktree │
├─────────────────────────────────────────────────────────────┤
│ 2. PLAN │
│ └── Understand requirements → Create implementation plan │
├─────────────────────────────────────────────────────────────┤
│ 3. CODE │
│ └── Implement → Test → Iterate │
├─────────────────────────────────────────────────────────────┤
│ 4. REVIEW │
│ └── Self-review → Fix issues → Validate │
├─────────────────────────────────────────────────────────────┤
│ 5. SHIP │
│ └── Create PR → Update ticket → Clean up worktree │
└─────────────────────────────────────────────────────────────┘Phase 1: Initiate
第一阶段:启动
Start work on a JIRA ticket:
bash
undefined开始处理JIRA工单:
bash
undefined1. List your tickets
1. 列出你的工单
npx tsx skills/jira/scripts/list_tickets.ts
npx tsx skills/jira/scripts/list_tickets.ts
2. Get ticket details
2. 获取工单详情
npx tsx skills/jira/scripts/get_ticket.ts PROJ-123
npx tsx skills/jira/scripts/get_ticket.ts PROJ-123
3. Clone repo if needed
3. 如有需要,克隆仓库
./skills/git-worktree/scripts/clone_repo.sh https://github.com/org/repo.git
./skills/git-worktree/scripts/clone_repo.sh https://github.com/org/repo.git
4. Create worktree for the ticket
4. 为工单创建工作树
./skills/git-worktree/scripts/create_worktree.sh repo PROJ-123-feature-name
./skills/git-worktree/scripts/create_worktree.sh repo PROJ-123-feature-name
5. Update ticket status
5. 更新工单状态
npx tsx skills/jira/scripts/update_ticket.ts PROJ-123 "In Progress"
npx tsx skills/jira/scripts/update_ticket.ts PROJ-123 "In Progress"
6. Navigate to worktree
6. 导航到工作树目录
cd ~/dev/<workspace>/repo-worktrees/PROJ-123-feature-name
undefinedcd ~/dev/<workspace>/repo-worktrees/PROJ-123-feature-name
undefinedPhase 2: Plan
第二阶段:规划
Create an implementation plan before coding:
- Read the ticket thoroughly - Understand requirements, acceptance criteria
- Research the codebase - Find related code, understand patterns
- Create plan document - Write to in the worktree:
PLAN.md
markdown
undefined编码前先制定实现方案:
- 仔细阅读工单 - 理解需求和验收标准
- 研究代码库 - 找到相关代码,理解代码模式
- 创建方案文档 - 在工作树目录中写入:
PLAN.md
markdown
undefinedPROJ-123: Feature Name
PROJ-123: 功能名称
Requirements
需求
- Requirement 1
- Requirement 2
- 需求1
- 需求2
Approach
实现方案
- Step one
- Step two
- 第一步
- 第二步
Files to Modify
需要修改的文件
- - Add X
src/module/file.ts - - Add tests
src/tests/file.test.ts
- - 添加X功能
src/module/file.ts - - 添加测试用例
src/tests/file.test.ts
Open Questions
待解决问题
- Q1?
4. **Get plan approval** - Review with stakeholder if needed- 问题1?
4. **获取方案批准** - 如有需要,与相关人员评审方案Phase 3: Code
第三阶段:编码
Implement the solution:
- Follow the plan - Work through requirements systematically
- Commit frequently - Small, atomic commits with clear messages
- Write tests - Unit tests for new code
- Run tests - Ensure nothing is broken
bash
undefined实现解决方案:
- 遵循方案 - 系统地完成各项需求
- 频繁提交 - 小而独立的提交,配合清晰的提交信息
- 编写测试 - 为新代码编写单元测试
- 运行测试 - 确保没有功能被破坏
bash
undefinedCommit format
提交信息格式
git commit -m "feat(module): description [PROJ-123]"
undefinedgit commit -m "feat(module): description [PROJ-123]"
undefinedPhase 4: Review
第四阶段:评审
Self-review before creating PR:
创建PR前先进行自我评审:
Code Review Checklist
代码评审检查清单
- Functionality - Does it work as expected?
- Tests - Are there adequate tests?
- Edge cases - Are edge cases handled?
- Error handling - Are errors handled gracefully?
- Performance - Any obvious performance issues?
- Security - Any security concerns?
- Documentation - Are complex parts documented?
- Style - Does it follow project conventions?
- 功能完整性 - 是否符合预期?
- 测试覆盖 - 测试是否充分?
- 边缘情况 - 是否处理了边缘情况?
- 错误处理 - 错误是否被优雅处理?
- 性能 - 是否有明显的性能问题?
- 安全性 - 是否有安全隐患?
- 文档 - 复杂部分是否有文档说明?
- 代码风格 - 是否遵循项目规范?
Run Reviews
执行评审
bash
undefinedbash
undefinedRun linter
运行代码检查工具
npm run lint
npm run lint
Run tests
运行测试
npm test
npm test
Run type check
运行类型检查
npm run typecheck
undefinednpm run typecheck
undefinedPhase 5: Ship
第五阶段:交付
Create PR and close the loop:
bash
undefined创建PR并完成闭环:
bash
undefined1. Push branch
1. 推送分支
git push origin PROJ-123-feature-name
git push origin PROJ-123-feature-name
2. Create PR
2. 创建PR
npx tsx skills/github/scripts/create_pr.ts org/repo PROJ-123-feature-name main "feat: Add feature [PROJ-123]"
npx tsx skills/github/scripts/create_pr.ts org/repo PROJ-123-feature-name main "feat: Add feature [PROJ-123]"
3. Add PR link to ticket
3. 向工单添加PR链接
npx tsx skills/jira/scripts/add_comment.ts PROJ-123 "PR created: https://github.com/org/repo/pull/XXX"
npx tsx skills/jira/scripts/add_comment.ts PROJ-123 "PR created: https://github.com/org/repo/pull/XXX"
4. Update ticket status
4. 更新工单状态
npx tsx skills/jira/scripts/update_ticket.ts PROJ-123 "Code Review"
npx tsx skills/jira/scripts/update_ticket.ts PROJ-123 "Code Review"
5. After merge, clean up
5. 合并后,清理工作树
./skills/git-worktree/scripts/remove_worktree.sh repo PROJ-123-feature-name
undefined./skills/git-worktree/scripts/remove_worktree.sh repo PROJ-123-feature-name
undefinedDetailed Guides
详细指南
- Planning Workflow - Detailed planning process
- Coding Workflow - Coding best practices
- Review Workflow - Review checklist and process
- 规划工作流 - 详细的规划流程
- 编码工作流 - 编码最佳实践
- 评审工作流 - 评审检查清单及流程