MCPcopy Create free account
hub / github.com/openai/plugins / hashFile

Function hashFile

plugins/plugin-eval/src/core/benchmark-workspace.js:177–181  ·  view source on GitHub ↗
(filePath)

Source from the content-addressed store, hash-verified

175}
176
177async function hashFile(filePath) {
178 const hash = createHash("sha1");
179 hash.update(await fs.readFile(filePath));
180 return hash.digest("hex");
181}
182
183async function visitSnapshot(rootPath, currentPath, entries) {
184 const directoryEntries = await fs.readdir(currentPath, { withFileTypes: true });

Callers 1

visitSnapshotFunction · 0.85

Calls 1

readFileMethod · 0.80

Tested by

no test coverage detected