Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions .github/workflows/skill-check.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
name: Skill Validator — PR Gate

on:
pull_request:
pull_request_target:
Comment thread
JanKrivanek marked this conversation as resolved.
Outdated
branches: [staged]
types: [opened, synchronize, reopened]
paths:
Expand All @@ -19,9 +19,10 @@ jobs:
skill-check:
runs-on: ubuntu-latest
steps:
- name: Checkout code
- name: Checkout PR code
uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4.3.1
with:
ref: ${{ github.event.pull_request.head.sha }}
fetch-depth: 0

# ── Download & cache skill-validator ──────────────────────────
Expand Down
12 changes: 11 additions & 1 deletion .github/workflows/skill-quality-report.yml
Original file line number Diff line number Diff line change
Expand Up @@ -248,7 +248,17 @@ jobs:

core.setOutput('title', title);
core.setOutput('body_file', 'report-body.md');
fs.writeFileSync('report-body.md', body);

// GitHub Issues/Discussions have a 65536 character body limit.
// Truncate the detail sections if the body exceeds the limit.
const MAX_BODY = 65000; // leave some margin
let finalBody = body;
if (finalBody.length > MAX_BODY) {
const truncMsg = '\n\n> **Note:** Output was truncated to fit GitHub\'s body size limit. See the [workflow run](https://github.com/' + context.repo.owner + '/' + context.repo.repo + '/actions/workflows/skill-quality-report.yml) for full output.\n';
finalBody = finalBody.substring(0, MAX_BODY - truncMsg.length) + truncMsg;
}

Comment thread
JanKrivanek marked this conversation as resolved.
Outdated
fs.writeFileSync('report-body.md', finalBody);

# ── Create Discussion (preferred) or Issue (fallback) ────────
- name: Create Discussion
Expand Down
Loading