Skip to content

Auto-sync vendored libkrun.h on Renovate bumps#111

Merged
JAORMX merged 1 commit into
mainfrom
chore/auto-sync-libkrun-header
Jul 10, 2026
Merged

Auto-sync vendored libkrun.h on Renovate bumps#111
JAORMX merged 1 commit into
mainfrom
chore/auto-sync-libkrun-header

Conversation

@JAORMX

@JAORMX JAORMX commented Jul 10, 2026

Copy link
Copy Markdown
Contributor

Problem

The automation we added in #106 left a manual gap: when Renovate bumps LIBKRUN_VERSION, the vendored krun/libkrun.h doesn't update automatically. We had to run task update-libkrun-header and open a follow-up PR (#110) — exactly the kind of manual step the automation was supposed to eliminate.

Fix

Add .github/workflows/sync-header.yaml — a GitHub Action that triggers when versions.env changes in a PR:

  1. Checks if LIBKRUN_VERSION actually changed (diffs against the base SHA). Skips libkrunfw-only bumps, which don't affect the header.
  2. Fetches include/libkrun.h from libkrun/libkrun@<new version>, prepends the SPDX/vendored comment block.
  3. Verifies it compiles (gcc -fsyntax-only) before committing.
  4. Commits back to the PR branch as github-actions[bot].

Renovate creates in-repo branches (same owner/repo, not forks), so GITHUB_TOKEN can push directly to the PR head.

Result

A Renovate libkrun bump PR now includes both the version pin and the vendored header in one PR — no follow-up needed. Scoped to renovate[bot] actor + LIBKRUN_VERSION changes only, so it doesn't fire on unrelated PRs.

Add a GitHub Action that triggers when versions.env changes in a PR.
If LIBKRUN_VERSION changed (not LIBKRUNFW-only), fetches the header
from libkrun/libkrun at the new version, verifies it compiles, and
commits it back to the PR branch — so a Renovate libkrun bump PR
includes the vendored header update automatically.

Removes the need for a manual task update-libkrun-header follow-up PR
after every libkrun version bump.
@JAORMX JAORMX merged commit 94011d8 into main Jul 10, 2026
7 checks passed
@JAORMX JAORMX deleted the chore/auto-sync-libkrun-header branch July 10, 2026 06:48
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.

1 participant