Upload via GUI (7543 Dateien)

This commit is contained in:
2026-10-22 06:57:20 +00:00
parent bac355eabb
commit 75cc88a011
50 changed files with 2018 additions and 0 deletions
+12
View File
@@ -0,0 +1,12 @@
import * as fs from 'fs-extra';
import * as crypto from 'crypto';
import { pipeline } from 'stream/promises';
import { d } from './debug';
export const sha = async (filePath) => {
d('hashing', filePath);
const hash = crypto.createHash('sha256');
hash.setEncoding('hex');
await pipeline(fs.createReadStream(filePath), hash);
return hash.read();
};
//# sourceMappingURL=sha.js.map