setup-exercode-course-repository
Compare original and translation side by side
🇺🇸
Original
English🇨🇳
Translation
ChineseSet up an Exercode course repository
配置 Exercode 课程仓库
Prepare the repository tooling required to author and evaluate Exercode course content. Do not create or modify learning content.
准备编写和评估 Exercode 课程内容所需的仓库工具。不要创建或修改学习内容。
Tracked tooling setup
将工具配置纳入版本控制
The repository tracks its tooling instead of ignoring it.
- contains
package.json,private: true, and the repository name.type: "module" - is an exact production dependency at its latest published version.
@exercode/problem-utils - is tracked.
bun.lock - Bun and Node.js are managed by mise with exact versions. Preserve an existing ,
mise.toml, or.mise.toml; when none exists, create.tool-versions..tool-versions - includes
.gitignore,node_modules/, and.DS_Store. It does not ignore.tmp/orpackage.json.bun.lock - Preserve compatible existing runtime versions, tools, dependencies, and scripts. Do not replace an existing mise or package setup wholesale.
仓库应跟踪其工具配置,而不是将其忽略。
- 包含
package.json、private: true和仓库名称。type: "module" - 是固定精确版本的生产依赖,应使用最新已发布版本。
@exercode/problem-utils - 应纳入版本控制。
bun.lock - Bun 和 Node.js 由 mise 管理,并固定为精确版本。保留现有的 、
mise.toml或.mise.toml;如果这些文件均不存在,则创建.tool-versions。.tool-versions - 包含
.gitignore、node_modules/和.DS_Store。不得忽略.tmp/或package.json。bun.lock - 保留兼容的现有运行时版本、工具、依赖和脚本。不要整体替换现有的 mise 或 package 配置。
Workflow
工作流
- Read the repository instructions and inspect only the tracked root tooling files, including ,
mise.toml, and.mise.tomlwhen present..tool-versions - Keep the repository's existing mise format. Ensure it pins exact Bun and Node.js versions, preserving compatible exact versions and every unrelated tool. If multiple mise files exist, do not duplicate a tool already declared in any of them; add missing tools to an existing TOML config. If none exists, create with the exact current stable Bun version and current LTS Node.js version.
.tool-versions - If a mise TOML config is present, run . Run
mise trust --yes, then use the installedmise installcommand normally for the remaining setup.bun - Create or update , then run
package.jsonsobun add --exact @exercode/problem-utils@latestandpackage.jsonagree.bun.lock - Ensure contains the required tooling entries without removing compatible existing entries.
.gitignore - Do not create, modify, move, validate, or evaluate any course, lecture, material, problem, contest, asset, or other learning-content file.
- 阅读仓库说明,并仅检查已纳入版本控制的根目录工具配置文件,包括存在时的 、
mise.toml和.mise.toml。.tool-versions - 保持仓库现有的 mise 配置格式。确保其固定了精确的 Bun 和 Node.js 版本,同时保留兼容的精确版本及所有无关工具。如果存在多个 mise 文件,不要重复声明任何文件中已有的工具;将缺失的工具添加到现有的 TOML 配置中。如果不存在任何 mise 文件,则创建 ,并写入当前稳定版 Bun 和当前 LTS 版 Node.js 的精确版本。
.tool-versions - 如果存在 mise TOML 配置,运行 。然后运行
mise trust --yes,并正常使用已安装的mise install命令完成其余配置。bun - 创建或更新 ,然后运行
package.json,确保bun add --exact @exercode/problem-utils@latest与package.json保持一致。bun.lock - 确保 包含必需的工具配置条目,同时不删除兼容的现有条目。
.gitignore - 不要创建、修改、移动、验证或评估任何课程、讲义、材料、题目、竞赛、资源或其他学习内容文件。