MCPcopy Index your code
hub / github.com/anomalyco/opencode / shutdown

Function shutdown

packages/opencode/src/cli/cmd/run/runtime.lifecycle.ts:91–107  ·  view source on GitHub ↗
(renderer: CliRenderer)

Source from the content-addressed store, hash-verified

89// back to passthrough before leaving split-footer mode, so pending stdout
90// doesn't get captured into the now-dead scrollback pipeline.
91function shutdown(renderer: CliRenderer): void {
92 if (renderer.isDestroyed) {
93 return
94 }
95
96 if (renderer.externalOutputMode === "capture-stdout") {
97 renderer.externalOutputMode = "passthrough"
98 }
99
100 if (renderer.screenMode === "split-footer") {
101 renderer.screenMode = "main-screen"
102 }
103
104 if (!renderer.isDestroyed) {
105 renderer.destroy()
106 }
107}
108
109function splashInfo(title: string | undefined, history: RunPrompt[]) {
110 if (title && !SessionApi.isDefaultTitle(title)) {

Callers 1

closeFunction · 0.70

Calls 1

destroyMethod · 0.65

Tested by

no test coverage detected