build-and-ship

Compare original and translation side by side

🇺🇸

Original

English
🇨🇳

Translation

Chinese

Build and Ship

构建与部署

This skill is a step of feature development. This skill builds a codebase, makes sure that all tests pass and ship it to the target environment.

本Skill是功能开发的一个环节。 该Skill用于构建代码库,确保所有测试通过,并将其部署到目标环境。

The Workflow

工作流程

You must always strictly follow this workflow when building and shipping a feature:
  1. Build the project
  2. Run the tests. If tests fail, understand the problem and go back to Phase 2.
  3. Clean up task files and update feature documentation (see below). Commit and push after that.
  4. Depending on whether you are shipping a Feature or a Fix:
  • If shipping a Feature: update the Feature markdown file with an "Implemented" badge:
    ![Status](https://img.shields.io/badge/status-implemented-brightgreen?style=flat-square)
    . This is IMPORTANT. Also update the
    README.md
    file in the
    docs/features
    folder, that contains the map of all features (index).
  • If shipping a Fix: update any Feature markdown file to which this fix is linked by closing any Open Point that was pointing at this fix. Make sure the Feature document is up-to-date with this fix. Note that you will find any linked Feature in the GitHub issue that the Fix is solving.
  1. Open a Pull Request. Always open a PR when you are done.
  2. Link the Github issue to the PR
Expected Output: The PR you have created.
必须始终严格遵循以下工作流程来构建和部署功能:
  1. 构建项目
  2. 运行测试。如果测试失败,排查问题并回到第2步。
  3. 清理任务文件并更新功能文档(见下文)。提交并推送代码。
  4. 根据你部署的是*Feature(功能)还是Fix(修复)*执行不同操作:
  • 如果部署Feature:在功能Markdown文件中添加“已实现”徽章:
    ![Status](https://img.shields.io/badge/status-implemented-brightgreen?style=flat-square)
    。这一点非常重要。同时更新
    docs/features
    文件夹中的
    README.md
    文件(该文件包含所有功能的索引地图)。
  • 如果部署Fix:更新与该修复相关的所有功能Markdown文件,关闭指向此修复的所有未解决项。确保功能文档已更新至包含该修复内容。注意:你可以在该修复对应的GitHub Issue中找到相关联的功能
  1. 发起Pull Request。完成工作后务必发起PR。
  2. 将GitHub Issue关联到该PR
预期输出: 你创建的PR。

Acceptance Criteria

验收标准

  • The project builds
  • The project's tests all pass
  • Feature markdown files are updated with resolved open questions and non-obvious API/domain decisions
  • A PR has been open
  • [ ] The GitHub issue has been linked to the PR so that when the PR is merged by the user, the issue automatically closes
  • If shipping a Feature: the Feature markdown file has been updated with the "Implemented" badge
Red Flags: Any of these behaviour or sentences are a BIG problem and mean that something is going wrong. Stop and rethinking what you should be doing.
  • Please proceed with the full implementation as planned. Do not wait for confirmation — implement all files now
  • You are re-implementing a whole feature from its spec when a change record indicated only a delta needed to be applied.
  • You applied the additions and modifications from a change record but skipped the removals.
  • 项目构建成功
  • 项目所有测试通过
  • 功能Markdown文件已更新,包含已解决的未决问题和非直观的API/领域决策
  • 已发起PR
  • GitHub Issue已关联到PR,以便用户合并PR时自动关闭该Issue
  • 如果部署的是Feature:功能Markdown文件已添加“已实现”徽章
警示信号: 以下任何行为或表述都是严重问题,意味着出现了错误。请停止操作并重新思考正确的做法。
  • 请按计划完成完整实现。不要等待确认——立即实现所有文件
  • 当变更记录仅表明需要进行增量修改时,你却从头重新实现整个功能。
  • 你应用了变更记录中的新增和修改内容,但跳过了删除操作