mirror of
https://github.com/deepseek-ai/deepseek-harness
synced 2026-08-15 21:04:50 +00:00
A launcher provides three values before the tree mounts: ctx.cmdlineArgs (get() is the whole interface) carrying everything after its own flags, ctx.appExit for a bounded exit, and ctx.appPatches for decisions a later recomposition must keep. An app's startup row injects cmdlineArgs and calls runStartup() with its own commander program. Rows the app configures inject its startup service, so they wait until the startup row has resolved their values and provided it; --help prints, disables those rows, and exits without the app ever starting. A changed row is recycled — disabled, then re-enabled with its new values — because a row's config is resolved when the Loader creates its fiber, while the row is still waiting. Recycling never touches inject: an inject update restarts the row from its unwrapped callback and loses the plugin's own static injections. A mount still in flight is allowed to settle first, so the disable has a fiber to dispose instead of racing one into existence.
804 B
804 B
boot/:共享的 app bin 启动粘合层
English | 中文
各 app bin 共享的、与渠道无关的启动库:apps/cli、scaffold/ 启动器与 examples/ demo bin 都消费它。
| 包 | 职责 | ctx 键 |
|---|---|---|
app-boot/ |
app bin 的共享启动粘合层:加载 .env、会明确报错的 Loader 保护机制、感知快照的配置解析,以及等待整棵树停稳的启动序列 |
(供各 bin 使用的库) |
cmdline/ |
启动器到应用的命令行交接,以及由应用持有的启动解析 | cmdlineArgs、appExit、appReady |
启动序列与个人配置约定见 app-boot/README.md;由应用持有的命令行见 cmdline/README.md。