From 3ea85afd4686a24816e6987afe9e609ccbf3773e Mon Sep 17 00:00:00 2001 From: Samual Norman Date: Thu, 17 Jun 2021 20:45:17 +0100 Subject: [PATCH] moved the percantage of characters saved to be with the number of characters saved to make it more obvious what it means (it also makes logs smaller) --- src/bin/hsm.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/bin/hsm.ts b/src/bin/hsm.ts index 7fd05a5..c004dbb 100755 --- a/src/bin/hsm.ts +++ b/src/bin/hsm.ts @@ -83,8 +83,8 @@ for (let arg of process.argv.slice(2)) { users.map(user => bold((configUsers[user] = configUsers[user] || { colour: colours[Math.floor(Math.random() * colours.length)](user) }).colour) ).join(", ") - } | ${bold(String(minLength))} chars from ${bold(String(srcLength))} | saved ${bold(String(srcLength - minLength))} chars | ${bold(`${Math.round((1 - (minLength / srcLength)) * 100)}%`)} compression | ${bold(`${resolvePath(hackmudPath, users[0], "scripts", basename(file, extname(file)))}.js`)}` - ) + } | ${bold(String(minLength))} chars from ${bold(String(srcLength))} | saved ${bold(String(srcLength - minLength))} (${bold(`${Math.round((1 - (minLength / srcLength)) * 100)}%`)}) | ${bold(`${resolvePath(hackmudPath, users[0], "scripts", basename(file, extname(file)))}.js`)}` + ) ) updateConfig() @@ -120,7 +120,7 @@ for (let arg of process.argv.slice(2)) { users.map(user => bold((configUsers[user] = configUsers[user] || { colour: colours[Math.floor(Math.random() * colours.length)](user) }).colour) ).join(", ") - } | ${bold(String(minLength))} chars from ${bold(String(srcLength))} | saved ${bold(String(srcLength - minLength))} chars | ${bold(`${Math.round((1 - (minLength / srcLength)) * 100)}%`)} compression | ${bold(`${resolvePath(hackmudPath, users[0], "scripts", basename(file, extname(file)))}.js`)}` + } | ${bold(String(minLength))} chars from ${bold(String(srcLength))} | saved ${bold(String(srcLength - minLength))} (${bold(`${Math.round((1 - (minLength / srcLength)) * 100)}%`)}) | ${bold(`${resolvePath(hackmudPath, users[0], "scripts", basename(file, extname(file)))}.js`)}` ), { genTypes } ) -- knotmirror 0.0.1