MCPcopy Create free account
hub / github.com/dethcrypto/dethcode / writeFile

Function writeFile

packages/ethereum-viewer/src/fs/fileSystem.ts:21–31  ·  view source on GitHub ↗
(path: string, content: string)

Source from the content-addressed store, hash-verified

19 );
20 },
21 writeFile(path: string, content: string) {
22 if (!path.startsWith("/")) path = "/" + path;
23
24 // const uri = vscode.Uri.from({ scheme: "memfs", path: path });
25 const uri = vscode.Uri.from({ scheme: "memfs", path: path });
26
27 fs.writeFile(uri, encoder.encode(content), {
28 create: true,
29 overwrite: true,
30 });
31 },
32 readFile(path: string): string {
33 if (!path.startsWith("/")) path = "/" + path;
34

Callers

nothing calls this directly

Calls 1

writeFileMethod · 0.80

Tested by

no test coverage detected