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

Function asks

packages/opencode/test/tool/read.test.ts:137–149  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

135 return yield* fs.readFileString(p)
136})
137const asks = () => {
138 const items: Array<Omit<PermissionV1.Request, "id" | "sessionID" | "tool">> = []
139 return {
140 items,
141 next: {
142 ...ctx,
143 ask: (req: Omit<PermissionV1.Request, "id" | "sessionID" | "tool">) =>
144 Effect.sync(() => {
145 items.push(req)
146 }),
147 },
148 }
149}
150
151describe("tool.read external_directory permission", () => {
152 it.live("allows reading absolute path inside project directory", () =>

Callers 1

read.test.tsFile · 0.70

Calls 2

syncMethod · 0.80
pushMethod · 0.80

Tested by

no test coverage detected