Monorepo Engineer
Scale one repository across teams: workspace layout, dependency pinning, version skew, hoisting traps, lockfile discipline, and fan-out CI that stays fast.
Path overview
单仓的收益是原子提交与统一工具链,代价是依赖与 CI 复杂度。本路径从工作区与依赖图讲起,覆盖钉扎、版本偏差与依赖混淆三类风险,再实战幽灵依赖、锁文件冲突与对等依赖风暴三大故障,收尾于矩阵 CI 与构建缓存。
Monorepos buy atomic commits and one toolchain at the price of dependency and CI complexity. This path covers workspaces, pinning, version skew, hoisting traps, lockfile failures, and matrix CI.
Stand up "pnpm Monorepo Workspaces" from its CLI, then modify "pnpm create turbo my-monorepo" and show the documented behavior still holds.
Next step: Fan Out CI with a GitHub Actions Matrix
⏱ 1.5h
Execute "Fan Out CI with a GitHub Actions Matrix" end to end, then repeat the last step with one parameter changed and compare "Four jobs appear in the run, one per operating system and Node version.".
Next step: Share a Docker Build Cache Across CI Runs
⏱ 0.5h
Run "Build with the gha cache backend for both import and export." from "Share a Docker Build Cache Across CI Runs" and confirm the documented result "Each branch writes its own cache scope and does not overwrite the default branch cache.".
Prerequisites: Fan Out CI with a GitHub Actions Matrix
Next step: Add a Dependency Lockfile Audit
⏱ 0.5h
Apply "Add a Dependency Lockfile Audit" to a monorepo task, checking that "Trace each advisory to the package that introduced it and choose a direct dependency update" appears after the "The owner of the transitive dependency and the available fixed version are visible." step.
Prerequisites: Share a Docker Build Cache Across CI Runs
Next step: Select Affected Packages for a Build
⏱ 0.5h
Build "Select Affected Packages for a Build" for monorepo code and verify [api,web] against both samples.
Prerequisites: Add a Dependency Lockfile Audit
Next step: Capstone: Monorepo Engineer
⏱ 0.42h
Deliver the "Build a Mini Package Manager with Semver Resolution" blueprint with "Conflict detection when two ranges on one package have no intersecting version, with a path" working and "Tarball fetch from a local registry with SHA-256 integrity checking before extraction" recorded as evidence.
Prerequisites: Add a Dependency Lockfile Audit, Select Affected Packages for a Build
Next step: Run the capstone's tests, publish the repository, and demo it to a reviewer.
⏱ 4h