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

Function stopShell

packages/opencode/src/effect/runner.ts:108–113  ·  view source on GitHub ↗
(shell: ShellHandle<A, E>)

Source from the content-addressed store, hash-verified

106 ).pipe(Effect.flatten)
107
108 const stopShell = (shell: ShellHandle<A, E>) =>
109 Effect.gen(function* () {
110 if (shell.ready) yield* shell.ready.await.pipe(Effect.exit, Effect.asVoid)
111 yield* Deferred.succeed(shell.cancelled, undefined).pipe(Effect.asVoid)
112 yield* Fiber.interrupt(shell.fiber)
113 })
114
115 const ensureRunning = (work: Effect.Effect<A, E>) =>
116 SynchronizedRef.modifyEffect(

Callers 1

makeFunction · 0.85

Calls 1

interruptMethod · 0.80

Tested by

no test coverage detected