Skip to content

Automate website release notes with branch-diffing script#3787

Merged
mattleibow merged 51 commits into
mainfrom
dev/automated-release-notes
Apr 28, 2026
Merged

Automate website release notes with branch-diffing script#3787
mattleibow merged 51 commits into
mainfrom
dev/automated-release-notes

Conversation

@mattleibow

@mattleibow mattleibow commented Apr 28, 2026

Copy link
Copy Markdown
Contributor

Replaces the manual release notes step in the release-publish workflow with an automated system that generates polished website release notes whenever code lands on main, release/* branches, or tags are pushed.

How it works

Workflow trigger → determine branch → invoke release-notes skill → create PR to main

The release-notes skill owns the entire process:

  1. Runs generate-release-notes.py --branch {branch} to diff against the predecessor branch
  2. Script writes raw PR data with YAML header directly to documentation/docfx/releases/{version}.md
  3. AI reads the raw file + TEMPLATE.md, rewrites with polished content
  4. TOC and index are regenerated automatically

Branch diffing logic

Branch pushed Diffs against Version file Status
main Latest release/{minor}.* branch {SKIASHARP_VERSION}.md unreleased
release/3.119.x Latest release/3.119.* versioned branch 3.119.{next}.md unreleased
release/4.147.0-preview.1 Previous release/4.147.* branch 4.147.0.md preview
release/3.119.2 release/3.119.2-preview.3 (last preview) 3.119.2.md stable

Changes

New/rewritten

  • generate-release-notes.py — Rewritten from tag-based to branch-diffing. New --branch command with semver-sorted predecessor detection. Writes YAML header + raw PR list directly to the version file. Auto-regenerates TOC/index. Three-state status detection (unreleased/preview/stable).

Updated

  • update-release-notes.md workflow — Simplified to 3 steps: determine branch, invoke skill, create PR. No duplicated formatting instructions.
  • release-notes/SKILL.md — Skill owns the script. Used both by the workflow and for manual regeneration.
  • release-publish/SKILL.md — Removed manual Step 7 (website notes). Tag push triggers the workflow automatically.
  • AGENTS.md — Updated command table.

Added

  • Polished release notes for 3.119.0, 3.119.1, 3.119.2, 3.119.3, 3.119.4, 4.147.0
  • Removed stale 4.133.0.md (never released)

Review feedback incorporated

  • Two rounds of Opus 4.7 + GPT-5.4 code reviews
  • Fixed: stable tag mapping, 3-state status, servicing off-by-one, fatal fetch, PR failure warnings, tag guard, paths-ignore suppression
 
Automate website release notes with branch-diffing script

Replace manual release-notes generation (release-publish Step 7) with an
automated system. The update-release-notes agentic workflow triggers on
pushes to main, release/*, and v* tags, determines the branch, and
delegates to the release-notes skill.

The skill owns the entire pipeline:
1. generate-release-notes.py --branch diffs against the semver-sorted
   predecessor branch and writes raw PR data with YAML front-matter
   directly to documentation/docfx/releases/{version}.md
2. AI polishes the raw file using TEMPLATE.md
3. TOC.yml and index.md are regenerated automatically

Branch diff logic:
- main: diffs against latest release/{minor}.* branch
- release/X.Y.x: diffs against latest release/X.Y.* versioned branch
- release/X.Y.Z[-preview.N]: diffs against previous branch in semver order

The script emits three-state status (unreleased/preview/stable) so the
AI selects the correct header format. Includes safety checks: fatal on
git fetch failure, warning+abort when >50% of PR fetches fail, refusal
to diff entire history when no release branches exist.

Also adds polished release notes for 3.119.0-3.119.4 and 4.147.0, and
removes stale 4.133.0.md (version was never released).

Co-authored-by: Matthew Leibowitz <mattleibow@live.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

@github-actions

github-actions Bot commented Apr 28, 2026

Copy link
Copy Markdown
Contributor

📦 Try the packages from this PR

Warning

Do not run these scripts without first reviewing the code in this PR.

Step 1 — Download the packages

bash / macOS / Linux:

curl -fsSL https://raw.githubusercontent.com/mono/SkiaSharp/main/scripts/get-skiasharp-pr.sh | bash -s -- 3787

PowerShell / Windows:

iex "& { $(irm https://raw.githubusercontent.com/mono/SkiaSharp/main/scripts/get-skiasharp-pr.ps1) } 3787"

Step 2 — Add the local NuGet source

dotnet nuget add source ~/.skiasharp/hives/pr-3787/packages --name skiasharp-pr-3787
More options
Option Description
--successful-only / -SuccessfulOnly Only use successful builds
--force / -Force Overwrite previously downloaded packages
--list / -List List available artifacts without downloading
--build-id ID / -BuildId ID Download from a specific build

Or download manually from Azure Pipelines — look for the nuget artifact on the build for this PR.

Remove the source when you're done:

dotnet nuget remove source skiasharp-pr-3787

@mattleibow
mattleibow force-pushed the dev/automated-release-notes branch 2 times, most recently from 87660bc to 46bc23a Compare April 28, 2026 15:19
Rewrites the update-release-notes agentic workflow to trigger on:
- Push to main (upcoming unreleased version)
- Push to release/* branches (preview, stable, servicing)
- Tag creation v* (finalize with NuGet/GitHub links)

Updates release-publish skill to remove manual Step 7 (now automatic).
Updates release-notes skill to position as manual override tool.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
@mattleibow
mattleibow force-pushed the dev/automated-release-notes branch from 46bc23a to a957bd7 Compare April 28, 2026 15:26
Replace the tag-based --unreleased command with a branch-aware
--branch BRANCH command that determines diff ranges from the
SkiaSharp branch model (main, release/X.Y.x, release/X.Y.Z,
release/X.Y.Z-preview.N).

Algorithm for each branch type:
- main: diff against latest release/{minor}.* branch (version
  read from SKIASHARP_VERSION in azure-templates-variables.yml)
- release/X.Y.x (servicing): diff against latest versioned
  release/X.Y.* branch
- release/X.Y.Z or release/X.Y.Z-preview.N: diff against
  previous branch in semver order within same minor

Semver sort key ensures correct ordering:
  X.Y.x < X.Y.Z-preview.N < X.Y.Z (stable)

Keep --version, --last, --update-toc commands unchanged.
Keep --unreleased as deprecated alias for --branch main.
Remove old tag-based find_baseline_tag/get_unreleased_prs.
Keep all helpers: compute_pr_effort, _fetch_skia_pr_effort,
TOC/index generation, version fetching.

Diagnostic info (branch, version, diff range, PR count) is
printed to stderr. PR list goes to stdout in same format.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
@github-actions

github-actions Bot commented Apr 28, 2026

Copy link
Copy Markdown
Contributor

📖 Documentation Preview

The documentation for this PR has been deployed and is available at:

🔗 View Staging Site
🔗 View Staging Docs
🔗 View Staging Gallery (Blazor)
🔗 View Staging Gallery (Uno Platform)
🔗 View Staging SkiaFiddle

This preview will be updated automatically when you push new commits to this PR.


This comment is automatically updated by the documentation staging workflow.

mattleibow and others added 21 commits April 28, 2026 18:31
…ction

Fixes from Opus 4.7 and GPT-5.4 code reviews:
- Fix stable tag → branch mapping (v3.119.2 → release/3.119.2, not release/3.119)
- Make git fetch fatal instead of silently using stale data
- Warn on PR fetch failures, fail if >50% fail
- Exclude .x branches from versioned branch predecessor candidates
- Remove paths-ignore to prevent suppressing tag push triggers
- Add release status detection (Status: released/unreleased) to script output
- Refuse to diff entire history when no release branches found

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
All metadata (branch, version, status, diff range, PR count) is now in
the YAML front-matter of the output file. No more stderr/stdout split.
--output is required with --branch.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
…flow

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Script --branch now writes raw PR data directly to
documentation/docfx/releases/{version}.md with YAML header.
AI reads and rewrites the same file with polished content.
No -o flag, no temp files, no split.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
- Fix tag push: derive BRANCH before the script call, not overwrite it
- Remove duplicate header format tables in workflow (was in Step 2 AND 3)
- Fix skill: reference YAML header, not stderr; remove redundant --update-toc step
- Clean up -o help text (only for --version/--last now)
- Renumber workflow steps (4 steps, not 5)

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Was looking for 'v4.147.0' exact tag (doesn't exist), now checks if
any release tag's base version matches (finds v4.147.0-preview.1.1).

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
release/3.119.x now resolves to version 3.119.5 (latest patch + 1)
and writes to 3.119.5.md instead of 3.119.x.md.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Replace raw YAML/PR-list stub with formatted website release notes
following TEMPLATE.md. Aggregates all 3 previews + stable into a
single rollup covering security hardening (Spectre, CFG,
BufferSecurityCheck), tvOS overloads, and community contributors.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Replaces raw PR data with formatted website release notes following the
template. Covers 1 new feature (PostScriptName), 1 security update (zlib),
7 bug fixes, and credits 4 community contributors.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Replace raw PR data with formatted release notes following the
TEMPLATE.md format. Covers dependency updates (libpng, libexpat,
brotli, libwebp), Spectre mitigations for Windows and Linux,
AoT crash fix, and Linux ARM64 fontconfig fix.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
First major version release (3.x → 4.x) powered by Skia milestone 147.
Covers variable font support, color font palettes, SKSamplingOptions,
Android Bionic builds, Tizen targets, and PolySharp C# 13 support.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Rewrite raw PR data into polished, template-formatted release notes:
- Skia m119 engine update, D3D on Windows, GL on Windows ARM
- tvOS SKMetalView, RISC-V64, LoongArch64, Alpine Linux
- 9 first-time community contributors credited with ❤️
- Security (CVE-2024-30105, libpng 1.6.44), 5 bug fixes
- Platform support table, preview 1 changelog link

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Rewrote raw PR data (101 PRs) into polished release notes following
the TEMPLATE.md format. Focused on user-facing changes: new GTK 4
views, Tizen/Bionic platform support, .NET 10 SDK, C# 13 on legacy
TFMs, and stability fixes (D3D12, tvOS, GTK4, Android SKGLView).
Omitted CI, skill, workflow, and docs-only changes.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Generated using the release-notes skill with branch-diffing script.
Covers 6 versions: 3.119.0, 3.119.1, 3.119.2, 3.119.3, 3.119.4, 4.147.0.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Ensures AI agents don't leave the YAML header and raw PR list behind
when rewriting the file with polished content.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Replace raw PR data with formatted website release notes following the
TEMPLATE.md structure. Aggregates all changes across 3 previews into a
single rollup covering security hardening (Spectre, CFG, BufferSecurityCheck)
and tvOS platform parity.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Replace stub content with polished release notes formatted from GitHub
Release data. Covers the new PostScriptName API, Metal rendering fixes,
Mac Catalyst opacity correction, WinUI loading fixes, zlib security
update, and credits four community contributors.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Replace raw PR list with formatted release notes following the
TEMPLATE.md structure. Highlights security hardening (Spectre
mitigations for Windows and Linux), four native dependency updates,
and two crash fixes.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Replace raw PR list with formatted release notes following the
TEMPLATE.md structure. Covers the stable release (April 29, 2025)
and Preview 1 (April 1, 2025), aggregating all changes into a
polished rollup with categorized features, bug fixes, security
updates, platform support table, and community contributor credits.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Replace raw placeholder with formatted release notes covering the first
4.x preview: Skia m147 engine bump, variable font and color palette APIs,
Tizen and Android Bionic platform support, and bug fixes.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Replace raw PR list with formatted release notes following the
TEMPLATE.md structure. Covers 101 PRs distilled into user-facing
highlights: GTK 4 view bindings, Linux Bionic support, Tizen
x64/arm64, D3D12 delay-loading, Android SKGLView TabBar fix,
.NET 10 SDK update, and net48 minimum framework bump.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
mattleibow and others added 2 commits April 28, 2026 20:22
- Fix AttributeError when PR author is null/ghost user
- Combine branch/tag detection into one if/else block (fixes
  GPT-5.4 finding where both blocks could execute in sequence)
- Collapse dead elif/else for preview-without-build-number

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Only two commands remain: --branch and --update-toc.
Removes ~100 lines of dead code (fetch_all_releases, fetch_release_body,
group_by_base, generate_raw_version_page, cmd_fetch_versions).

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
mattleibow and others added 18 commits April 28, 2026 21:33
Replace raw PR data with formatted release notes following the TEMPLATE.
Covers Preview 1 content (variable fonts, color palettes, Tizen/Bionic
platforms, SKSamplingOptions, SKGLView fix) and adds a 'Coming in the
Next Preview' section for 3 unreleased changes on main.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Replace raw PR data with formatted release notes covering Preview 1
(107 PRs) and upcoming backports on release/3.119.x.

Key highlights:
- GTK 4 view support (SkiaSharp.Views.Gtk4)
- Linux Bionic and Tizen x64/arm64 native builds
- D3D12 delay-loading for Windows without DX12
- PolySharp for C# 13 on legacy TFMs
- MAUI SKGLView tab-switch rendering fix
- Complete sample app refresh with Blazor WASM Gallery
- Upcoming: libpng 1.6.58 security update

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Versioned branches (release/X.Y.Z*) write to {version}.md.
Main branches (main, release/X.Y.x) write to {version}-next.md.
TOC and index show -next files as '(Next)' entries.
Removes ensure_upcoming_file and (Upcoming) tag.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Replace raw PR data with formatted release notes following the
TEMPLATE.md structure. Highlights the Uno gallery fix by
@ramezgerges and omits CI/version-bump noise.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Format the raw PR list into polished release notes following
TEMPLATE.md. The only user-facing change since Preview 1 is the
libpng bump to 1.6.58; CI backports and metadata fixes are omitted
as noise per the formatting rules.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Replace raw PR data with formatted release notes following TEMPLATE.md.
Aggregates all changes across preview 1-3 and stable release:
- Security: Spectre mitigation (Windows/Linux), CFG, BufferSecurityCheck
- Platform: tvOS SKSurface.Create overloads
- Community: @MartinZikmund, @Aguilex, @sshumakov

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Write full release notes for 4.147.0-preview.1 covering the major
version leap from 3.x to 4.x, Skia engine upgrades through milestone
147, variable font support, color font palettes, new Tizen and Android
Bionic platform targets, SKSamplingOptions for surface drawing, and
security dependency updates.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Add missing 'removed unused dependencies' entry (#3463), update platform
table, and add CI/docs summary line to preview section.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Add missing issue reference (#3157) to the SKImage.FromPicture fix and
include the broader Linux compatibility item (#3209) in the Platform
section.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Replace raw PR data with formatted release notes covering:
- GTK 4 views, Android Bionic, and Tizen x64/arm64 platform support
- .NET 10 SDK upgrade with workload version set pinning
- SKManagedStream refactor, PolySharp for C# 13, net48 TFM bump
- D3D12 delay-load, SKGLView TabBar fix, tvOS build fixes
- Interactive Blazor WASM Gallery and modernized sample projects

Community contributors: @4Darmygeometry, @SimonvBez, @ramezgerges

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
8 files: 3.119.0-4, 4.147.0 (released) + 3.119.4-next, 4.147.0-next (unreleased).
-next entries now appear above their released counterpart in TOC/index.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Replace raw PR list with polished release notes following the TEMPLATE.md
format. The 4 backported PRs since Preview 1 include:

- libpng bump to 1.6.58 (security/hardening)
- cgmanifest.json Skia milestone fix (governance accuracy)
- 2 CI-only backports (omitted as noise per template rules)

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Polish the raw PR list into formatted release notes following the
TEMPLATE.md style. Omits noise (CI workflow fix, version bump) and
highlights the two community contributions from @ramezgerges:
SkiaFiddle UX improvements and Skottie package downgrade fix.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Refresh the polished release notes with improved wording, corrected
Full Changelog link (v3.116.1...v3.119.0 comparing against previous
stable), and minor formatting consistency improvements.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Restructured sections to match TEMPLATE.md:
- Security is now its own top-level section (not nested under New Features)
- Dependencies moved to its own top-level section
- Improved descriptions and Platform Support table emojis
- Cleaned up trailing noise line

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Rewrote release notes with improved categorization:
- Separated Bug Fixes from Platform improvements
- Moved PostScriptName under Text & Fonts category
- Removed CI-only contributor from community table
- Improved highlights and descriptions

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Tizen was incorrectly listed under 🍎 Apple. Changed to 📺 Tizen
since it's a Samsung platform, not an Apple one.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
@mattleibow
mattleibow merged commit b54af5b into main Apr 28, 2026
5 of 6 checks passed
@mattleibow
mattleibow deleted the dev/automated-release-notes branch April 28, 2026 20:53
github-actions Bot pushed a commit that referenced this pull request Apr 28, 2026
github-actions Bot added a commit that referenced this pull request Apr 29, 2026
Add docs landing page improvement (#3794), note CI and workflow
automation improvements (#3755, #3787, #3802, #3805, #3808, #3811,
#3812, #3813), and expand highlights paragraph.

Community sample fixes by @ramezgerges (#3785, #3790) were already
present.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

1 participant