Skip to content

armgit / zed

Public Imported from GitHub
0

Code at the speed of thought – Zed is a high-performance, multiplayer code editor from the creators of Atom and Tree-sitter.

Fix guided tour false positive in PR size check (#51964)

John D. Swansonb78687263dad
diff --git a/.github/workflows/pr-size-check.yml b/.github/workflows/pr-size-check.yml
index 940c619e0cf..bbd60d727e1 100644
--- a/.github/workflows/pr-size-check.yml
+++ b/.github/workflows/pr-size-check.yml
@@ -144,7 +144,11 @@ jobs:
const alreadyCommented = comments.some(c => c.body.includes(MARKER));
if (!alreadyCommented) {
- const prBody = context.payload.pull_request.body || '';
+ // Strip HTML comments before checking — the PR template's
+ // placeholder text contains "guided tour" and "read in order"
+ // which causes false positives.
+ const prBody = (context.payload.pull_request.body || '')
+ .replace(/<!--[\s\S]*?-->/g, '');
const guidedTourPresent = /how to review|guided tour|read.*in.*order/i.test(prBody);
let body = `${MARKER}\n`;