MCPcopy Create free account
hub / github.com/backnotprop/plannotator / hashSourceBytes

Function hashSourceBytes

packages/shared/source-save-node.ts:27–29  ·  view source on GitHub ↗
(bytes: Uint8Array)

Source from the content-addressed store, hash-verified

25} from "./source-save";
26
27export function hashSourceBytes(bytes: Uint8Array): string {
28 return `sha256:${createHash("sha256").update(bytes).digest("hex")}`;
29}
30
31function isFileExistsError(error: unknown): boolean {
32 return (

Callers 2

readSourceFileSnapshotFunction · 0.85

Calls 1

updateMethod · 0.80

Tested by

no test coverage detected