File tree 1 file changed +3
-2
lines changed
1 file changed +3
-2
lines changed Original file line number Diff line number Diff line change 5
5
name : Check binary size
6
6
7
7
on :
8
- pull_request :
8
+ pull_request_target :
9
9
branches :
10
10
- master
11
11
@@ -69,13 +69,14 @@ jobs:
69
69
const diff_str = `${plus}${diff}B`;
70
70
71
71
if (diff !== 0) {
72
+ const percent = (((updated / reference) - 1) * 100).toFixed(2);
72
73
// The body is created here and wrapped so "weirdly" to avoid whitespace at the start of the lines,
73
74
// which is interpreted as a code block by Markdown.
74
75
const body = `Below is the size of a hello-world Rust program linked with libstd with backtrace.
75
76
76
77
Original binary size: **${reference}B**
77
78
Updated binary size: **${updated}B**
78
- Difference: **${diff_str}**`;
79
+ Difference: **${diff_str}** (${percent}%) `;
79
80
80
81
github.rest.issues.createComment({
81
82
issue_number: context.issue.number,
You can’t perform that action at this time.
0 commit comments