add separator between PR body and bundle stats (#6715)

* add seperator line before bundle stats post

* note

* [autofix.ci] apply automated fixes

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
This commit is contained in:
Matt Fiddaman
2026-01-19 16:39:36 +00:00
committed by GitHub
parent 3c302b3af9
commit 502babd310
2 changed files with 13 additions and 1 deletions

View File

@@ -14,6 +14,9 @@ import process from 'node:process';
import { Octokit } from '@octokit/rest';
const BOT_BOUNDARY_MARKER = '<!--- actual-bot-sections --->';
const BOT_BOUNDARY_TEXT = `${BOT_BOUNDARY_MARKER}\n<hr />`;
function parseArgs(argv) {
const args = {
commentFile: null,
@@ -158,7 +161,10 @@ function upsertBlock(existingBody, block, markers) {
}
const separator = body.endsWith('\n') ? '\n' : '\n\n';
return `${body}${separator}${block.trim()}`;
const boundary = body.includes(BOT_BOUNDARY_MARKER)
? ''
: `${BOT_BOUNDARY_TEXT}\n\n`;
return `${body}${separator}${boundary}${block.trim()}`;
}
async function updatePullRequestBody(

View File

@@ -0,0 +1,6 @@
---
category: Maintenance
authors: [matt-fidd]
---
Add separator between PR body and bundle statistics