MCPcopy
hub / github.com/anomalyco/opencode / provide

Function provide

packages/core/test/location-filesystem.test.ts:13–21  ·  view source on GitHub ↗
(directory: string)

Source from the content-addressed store, hash-verified

11import { it } from "./lib/effect"
12
13const provide = (directory: string) =>
14 Effect.provide(
15 LayerNode.compile(FileSystem.node, [
16 [
17 Location.node,
18 Layer.succeed(Location.Service, Location.Service.of(location({ directory: AbsolutePath.make(directory) }))),
19 ],
20 ]),
21 )
22
23const withTmp = <A, E, R>(f: (directory: string) => Effect.Effect<A, E, R>) =>
24 Effect.acquireRelease(

Callers 1

Calls 2

locationFunction · 0.90
makeMethod · 0.45

Tested by

no test coverage detected