mirror of
https://ghproxy.cflmy.top/https://github.com/deepseek-ai/deepseek-harness.git
synced 2026-11-29 00:30:04 +08:00
Each Session now has three directories: the immutable original project in the header, the workspace root, and the current directory. `relocate` registers an entered checkout as an anchor through the optional `anchor` of one working-directory/change event, and the new workspaceRoot projection selects the longest anchor containing the current directory, so an ordinary cd inside a checkout moves only the cursor while entering another checkout moves the root with it. A log without anchors keeps the original project as its only anchor. Worktree creation relocates instead of setting the directory; a subagent that starts inside its parent's relocated root inherits that root; the SDK working-directory methods return the root beside cwd; the user context names the root while it differs from the current directory, and a notice that selects another root ends with it. Consumers keep reading the header or the current directory until a later change moves them. Refs #2658