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

Function read

packages/core/test/git.test.ts:69–71  ·  view source on GitHub ↗
(file: string)

Source from the content-addressed store, hash-verified

67}
68
69function read(file: string) {
70 return Effect.promise(() => fs.readFile(file, "utf8")).pipe(Effect.map((content) => content.replace(/\r\n/g, "\n")))
71}
72
73async function initRepo(directory: string) {
74 await $`git init`.cwd(directory).quiet()

Callers 2

git.test.tsFile · 0.70
read-filesystem.tsFile · 0.50

Calls

no outgoing calls

Tested by

no test coverage detected