Skip to content

release workflow: follow-ups from PR #4#7

Merged
jonwiggins merged 4 commits intomainfrom
optio/task-9bd13022-770a-4417-b0bc-bd8efd3449ca
Apr 22, 2026
Merged

release workflow: follow-ups from PR #4#7
jonwiggins merged 4 commits intomainfrom
optio/task-9bd13022-770a-4417-b0bc-bd8efd3449ca

Conversation

@jonwiggins
Copy link
Copy Markdown
Owner

Closes #6

What changed

Addresses all follow-ups from #4 for the release workflow:

Coverage gaps

  • Add x86_64-apple-darwin target — Intel Macs get pre-built binaries (cross-compiled from ARM64 macos-14 runner)
  • Pin runnersmacos-latestmacos-14, windows-latestwindows-2022 (matches the deliberate ubuntu-22.04 pin)

Release hygiene

  • Tag/version consistency check — new check-version job that fails if v$CARGO_VERSION ≠ tag name; prevents mistyped tags from shipping mislabeled binaries
  • Strip release binaries[profile.release] strip = true in Cargo.toml; meaningfully shrinks binary size
  • Generate SHA256SUMSsha256sum xmllint_* > SHA256SUMS uploaded as a release asset for integrity verification

Hardening / DX

  • Pin third-party actions to commit SHAs — all 8 action references pinned to full SHA with version comment (e.g., actions/checkout@34e11487... # v4)
  • Dependabot for GitHub Actions.github/dependabot.yml added to auto-update SHA pins weekly
  • Faster cross installtaiki-e/install-action@v2 with tool: cross replaces cargo install cross --locked (downloads pre-built binary instead of compiling from source)
  • Add workflow_dispatch — allows dry-running the full build matrix without cutting a tag; release creation is gated on startsWith(github.ref, 'refs/tags/') so manual runs only build, they don't publish

Note on workflow file

The updated workflow is committed as .github/release.yml.pending because the CI token lacks the workflow scope required by GitHub to modify files under .github/workflows/. To apply:

mv .github/release.yml.pending .github/workflows/release.yml
git add .github/workflows/release.yml .github/release.yml.pending
git commit -m "ci: apply hardened release workflow"
Full release.yml diff (click to expand)

Key changes to .github/workflows/release.yml:

  • on.workflow_dispatch trigger added
  • New check-version job with tag/Cargo.toml consistency check
  • build job: 5 targets (added x86_64-apple-darwin), all runners pinned, all actions SHA-pinned
  • cross installed via taiki-e/install-action instead of cargo install
  • release job: generates SHA256SUMS, gated on tag push, runner pinned to ubuntu-22.04

How to test

  1. Cargo.toml — verify [profile.release] has strip = true
  2. Dependabot — verify .github/dependabot.yml targets github-actions ecosystem
  3. Workflow — review .github/release.yml.pending for correctness, then apply it (requires workflow token scope)
  4. After applying, trigger a workflow_dispatch run to validate the build matrix without cutting a tag

jonwiggins and others added 4 commits April 22, 2026 05:29
- Strip release binaries (profile.release strip = true)
- Add Dependabot config for GitHub Actions SHA pin updates

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
…cope to apply)

The updated .github/workflows/release.yml is saved as .github/release.yml.pending
because the CI token lacks the 'workflow' scope required to modify workflow files.

To apply: mv .github/release.yml.pending .github/workflows/release.yml

Changes include:
- Add x86_64-apple-darwin target for Intel Macs
- Pin runners to macos-14 and windows-2022
- Add tag/version consistency check
- Generate SHA256SUMS for integrity verification
- Pin all third-party actions to commit SHAs
- Use taiki-e/install-action for faster cross installation
- Add workflow_dispatch for dry-run builds

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Collapse inner `if` conditions into match guards across 4 files to
satisfy the `collapsible_match` lint that is now enforced in Rust 1.95
stable with pedantic clippy.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
rustfmt (rust 1.95) collapses two multiline match arms in the validation
module onto single lines; apply cargo fmt. Clippy's collapsible_match
also fires on the html5lib tree construction test harness — lift the
inner `if !line.is_empty()` checks into match guards to match the fix
already applied to the library sources in 29f404e.
@jonwiggins jonwiggins merged commit af2e861 into main Apr 22, 2026
6 of 7 checks passed
@jonwiggins jonwiggins deleted the optio/task-9bd13022-770a-4417-b0bc-bd8efd3449ca branch April 22, 2026 06:56
jonwiggins added a commit that referenced this pull request Apr 22, 2026
Bump to 0.4.2 and apply the hardened release workflow that was committed
as .github/release.yml.pending in PR #7 but couldn't be moved into
.github/workflows/ from a token without the workflow scope.

Release changes since 0.4.1:
- serial: eliminate implicit xml namespace for exclusive c14n (#5)
- ci: release workflow with per-platform xmllint binaries (#4, #7)
- release profile: strip = true for smaller binaries
- dependabot: weekly github-actions updates
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

release workflow: follow-ups from PR #4

1 participant