MCPcopy Create free account
hub / github.com/anomalyco/opencode / updateShell

Function updateShell

packages/core/src/session/message-updater.ts:61–69  ·  view source on GitHub ↗
(shell)

Source from the content-addressed store, hash-verified

59 })
60 },
61 updateShell(shell) {
62 return Effect.sync(() => {
63 const index = activeShellIndex(shell.callID)
64 if (index < 0) return
65 const current = state.messages[index]
66 if (current?.type !== "shell") return
67 state.messages[index] = shell
68 })
69 },
70 appendMessage(message) {
71 return Effect.sync(() => {
72 state.messages.push(message)

Callers

nothing calls this directly

Calls 2

activeShellIndexFunction · 0.85
syncMethod · 0.80

Tested by

no test coverage detected