Document coverage workflow strategies · actions/upload-code-coverage@32ff83e · GitHub
Skip to content

Commit 32ff83e

Browse files
committed
Document coverage workflow strategies
1 parent 293c9eb commit 32ff83e

4 files changed

Lines changed: 116 additions & 0 deletions

File tree

‎CHANGELOG.md‎

Lines changed: 6 additions & 0 deletions

‎README.md‎

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -91,6 +91,8 @@ on:
9191

9292
Push-only workflows can upload PR coverage by granting `pull-requests: read`. Repositories may also use broader `push` triggers for other CI requirements; pushes without an open PR are skipped safely.
9393

94+
See [Choosing a workflow strategy](docs/workflow-strategies.md) for trigger and job layouts, or [Upgrading](docs/upgrading.md) for version and compatibility guidance.
95+
9496
## Full example (separate upload job)
9597

9698
```yaml

‎docs/upgrading.md‎

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
# Upgrading
2+
3+
Review the [changelog](../CHANGELOG.md) before upgrading.
4+
5+
## Version references
6+
7+
Each release uses a complete semantic version tag such as `v1.4.3`. The corresponding major tag remains a supported movable alias:
8+
9+
```yaml
10+
- uses: actions/upload-code-coverage@v1
11+
```
12+
13+
Workflows using `v1` receive new `v1.x.x` releases when the major tag advances. Workflows pinned to a complete version or commit SHA must update that reference explicitly.
14+
15+
## Compatibility
16+
17+
Existing workflows can upgrade without changing their triggers, job layout, action inputs, or permissions.
18+
19+
Push-only workflows should keep `pull-requests: read` so the action can discover an open pull request for a pushed branch. For a non-default branch push without an open pull request, the action now skips successfully instead of attempting an upload that the API rejects.

‎docs/workflow-strategies.md‎

Lines changed: 89 additions & 0 deletions

0 commit comments

Comments
 (0)