You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Add two reporting features that share the report markdown:
- Sticky PR comment: github_pr.go now lists the PR's comments and PATCHes
the one carrying a hidden marker instead of POSTing a new comment on
every push. Adds Unmarshal to the json client.
- Job summary: a StepSummary reporter writes the report to
$GITHUB_STEP_SUMMARY when set, so coverage shows on the Actions run page
even on fork PRs that can't be commented on. Wired into the workflow by
mounting and passing the summary file.
Extracts the shared buildMarkdownReport used by both the comment and the
summary, and updates README/AGENTS docs and tests.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Copy file name to clipboardExpand all lines: README.md
+3Lines changed: 3 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -346,8 +346,11 @@ docker run --rm \
346
346
| `BUILD_PULL_REQUEST_NUMBER` | the PR number to comment on |
347
347
| `REPOSITORY_ORG` | repository owner / org |
348
348
| `REPOSITORY_NAME` | repository name |
349
+
| `GITHUB_STEP_SUMMARY` | set automatically by GitHub Actions. When present, the plugin also writes the report to the [job summary](https://docs.github.com/en/actions/using-workflows/workflow-commands-for-github-actions#adding-a-job-summary), so coverage shows on the run page even on fork PRs that can't be commented on |
349
350
350
351
> The PR comment is posted only when `gh_api_key` **and** all three build-context values are present. Otherwise the plugin prints to the console and exits successfully.
352
+
>
353
+
> The comment is **sticky**: on later pushes the plugin updates its existing comment in place instead of posting a new one each time. In GitHub Actions, mount the summary file (`-v "$GITHUB_STEP_SUMMARY:$GITHUB_STEP_SUMMARY" -e GITHUB_STEP_SUMMARY`) to get the job-summary output — see [`.github/workflows/pr-coverage.yml`](.github/workflows/pr-coverage.yml).
0 commit comments