|
44 | 44 | name: termlens-report-ci-${{ matrix.os }} |
45 | 45 | cli-version: "0.10.1" # checked against the manifest by check-skill-version.sh |
46 | 46 |
|
| 47 | + # The public API against the last published release. |
| 48 | + # |
| 49 | + # `--release-type` is FORCED, never inferred, and the reason is measured |
| 50 | + # rather than assumed. Removing `Config::kernel` from launchbound-space |
| 51 | + # while bumping the manifest to 3.0.0 in the same PR: |
| 52 | + # |
| 53 | + # inferred -> "0 checks: 0 pass, 254 skip", exit 0 |
| 54 | + # --release-type patch -> "1 major and 0 minor checks failed", exit 100 |
| 55 | + # |
| 56 | + # cargo-semver-checks compares the manifest version to the baseline and |
| 57 | + # runs only the lints that bump would not already excuse. Declare the major |
| 58 | + # bump in the same commit as the break and it has nothing left to say. That |
| 59 | + # is the hole: the gate agrees with whatever the PR claims about itself. |
| 60 | + # |
| 61 | + # `patch` means "no API change of any kind is excused", so every lint |
| 62 | + # fires. It does NOT forbid additions -- cargo-semver-checks only reports |
| 63 | + # breaking changes, so a new `pub fn` passes (verified: 223 checks, 223 |
| 64 | + # pass, with a `pub use` added). |
| 65 | + # |
| 66 | + # A deliberate break carries the `breaking` label, which switches this to |
| 67 | + # `major`. Three of the eleven published crates are binary-only and have no |
| 68 | + # library API; the eight that do are all covered by --workspace. |
| 69 | + # |
| 70 | + # `baseline-version` is a literal, moved in the release PR after publish -- |
| 71 | + # left at the old release it would compare against a version nobody can |
| 72 | + # install, and moved before publish it would compare against one that does |
| 73 | + # not exist yet. |
| 74 | + semver: |
| 75 | + runs-on: ubuntu-latest |
| 76 | + steps: |
| 77 | + - uses: actions/checkout@v4 |
| 78 | + - name: Install pinned toolchain from rust-toolchain.toml |
| 79 | + run: rustup show |
| 80 | + # A prebuilt binary, downloaded every run: never built from source, and |
| 81 | + # never restored from a cache. A gate that reports on whatever a cache |
| 82 | + # held the day it was filled is not reporting on this PR. |
| 83 | + - uses: taiki-e/install-action@v2 |
| 84 | + with: |
| 85 | + tool: cargo-semver-checks |
| 86 | + - name: Compare the public API against the published baseline |
| 87 | + env: |
| 88 | + RELEASE_TYPE: ${{ contains(github.event.pull_request.labels.*.name, 'breaking') && 'major' || 'patch' }} |
| 89 | + run: | |
| 90 | + echo "release-type: $RELEASE_TYPE" |
| 91 | + cargo semver-checks --workspace \ |
| 92 | + --baseline-version 2.1.0 \ |
| 93 | + --release-type "$RELEASE_TYPE" |
| 94 | +
|
47 | 95 | # MSRV applies to the crates that do not need the pinned nightly |
48 | 96 | # (CONTRIBUTING.md); checked against the committed lockfile. |
49 | 97 | msrv: |
|
0 commit comments