UNPKG

@clickup/pg-mig

Version:

PostgreSQL schema migration tool with microsharding and clustering support

10 lines (8 loc) 295 B
import crypto from "crypto"; import { readFileSync } from "fs"; export function filesHash(fileNames: string[]): string { const contents = fileNames.map((fileName) => readFileSync(fileName).toString(), ); return crypto.createHash("sha256").update(contents.join("\n")).digest("hex"); }