blob: 14059b5b4d57b75daeb51b7a5ffe2a88d483e562 (
plain)
1
2
3
4
5
6
7
8
|
import { Hash } from "checksum/mod.ts";
export async function calculateFileHash(
filePath: string,
): Promise<string> {
const content = await Deno.readFile(filePath);
return new Hash("md5").digest(content).hex();
}
|