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

Function input

packages/opencode/test/fixture/plug-worker.ts:25–37  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

23}
24
25function input() {
26 const raw = process.argv[2]
27 if (!raw) {
28 throw new Error("Missing plug worker input")
29 }
30
31 const msg = JSON.parse(raw) as Partial<Msg>
32 if (!msg.dir || !msg.target || !msg.mod) {
33 throw new Error("Invalid plug worker input")
34 }
35
36 return msg as Msg
37}
38
39function deps(msg: Msg): PlugDeps {
40 return {

Callers 1

mainFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected