0
Fork 0
mirror of https://github.com/logto-io/logto.git synced 2024-12-16 20:26:19 -05:00

ci: fix file size diff comment display (#784)

This commit is contained in:
Gao Sun 2022-05-10 12:26:01 +08:00 committed by GitHub
parent 2161856bcd
commit 4cace12f00
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -80,12 +80,12 @@ jobs:
const filesHeader = `|Name|Diff|\n|---|---|\n`;
const filesData = result.map((row) => {
const [diff, filename] = row.split('\t');
return `|${filename}|${format(Number(diff))}|\n`;
});
return `|${filename}|${format(Number(diff))}|`;
}).join('\n');
return `#### Size Diff (Compare to \`master\`)\n**Total** ${format(diff)}\n${
result.length ? `\n${filesHeader}${filesData}` : ''
}`;
}\n`;
- uses: marocchino/sticky-pull-request-comment@v2
with: