p9: wire SetWorkDir into workdir write handler
Validate the path and propagate the change to the agent core (which updates the execute server and rebuilds the system prompt) before updating the session's cached workdir field. Return early on error. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
parent
cf777b9420
commit
071add996c
|
|
@ -767,6 +767,10 @@ func (s *Server) handleWrite(path, input string) {
|
|||
})
|
||||
|
||||
case "workdir":
|
||||
if err := sess.core.SetWorkDir(input); err != nil {
|
||||
fmt.Fprintf(os.Stderr, "olliesrv: workdir: %v\n", err)
|
||||
return
|
||||
}
|
||||
sess.mu.Lock()
|
||||
sess.workdir = input
|
||||
sess.mu.Unlock()
|
||||
|
|
|
|||
Reference in New Issue