From 04c39cf0b67dbda311d2d8f0f2cc97b5b6e52908 Mon Sep 17 00:00:00 2001 From: Nadia Barbosa Date: Tue, 9 Apr 2019 17:40:19 -0700 Subject: Debug dump --- scripts/check_binary_size.js | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/scripts/check_binary_size.js b/scripts/check_binary_size.js index 5a8aa70b1b..42cb451acf 100755 --- a/scripts/check_binary_size.js +++ b/scripts/check_binary_size.js @@ -40,6 +40,8 @@ function getPriorSize() { console.log('No merge base available.'); return Promise.resolve(null); } + + console.log(`mergeBase: ${mergeBase}`); return github.checks.listForRef({ owner: 'mapbox', @@ -51,7 +53,9 @@ function getPriorSize() { console.log('No matching check found.'); return Promise.resolve(null); } - return +run.output.summary.match(/`.*` is (\d+) bytes/)[1]; + const priorSize = +run.output.summary.match(/`.*` is (\d+) bytes/)[1]; + console.log("priorSize: " + priorSize); + return priorSize }); } @@ -62,6 +66,7 @@ github.apps.createInstallationToken({installation_id: SIZE_CHECK_APP_INSTALLATIO const title = (() => { if (prior) { const change = size - prior; + console.log(`change: ${size} - ${prior} = ${change}`) const percent = (change / prior) * 100; return `${change >= 0 ? '+' : ''}${prettyBytes(change)} ${percent.toFixed(3)}% (${prettyBytes(size)})`; } else { -- cgit v1.2.1