This commit is contained in:
afonya2 2025-05-17 17:58:36 +02:00
parent d17ea51357
commit 0ebddb272d
Signed by: afonya
GPG key ID: EBB9C4CAFAAFB2DC
2 changed files with 2 additions and 2 deletions

View file

@ -64,7 +64,7 @@ async function main() {
}
if (counter % 1000 == 0) {
let timeTook = Math.floor((Date.now() - startTime) / 100) / 10
console.log(`Last string: ${str}, Last hash: ${h}, Collisions: ${collisions.length}, Time: ${timeTook}s`)
console.log(`Last string: ${str}, Last hash: ${h}, Collisions: ${collisions.length}, Time: ${timeTook}s, Speed: ${Math.floor(counter/timeTook*10)/10} hash/s`)
await sleep(1)
}
if (counter % 10000 == 0) {

View file

@ -8,7 +8,7 @@ function printHelp() {
console.log("IGA commandline tool v" + version)
console.log("Usage: tsx hash.ts <hash|verify> <input file> [<hash to verify>] [options]");
console.log("Options:");
console.log("[<salt = 0>] [<iterations = 32>] [<length of the hash = 32>]");
console.log("[<salt = 0>] [<length of the hash = 32>]");
}
if (args[0] == "hash") {