Skip to content

Add a pull request build for the site and every platform - #20

Merged
gmurray81 merged 5 commits into
vnextfrom
btraykov/pr-build-ci
Nov 11, 2026
Merged

gmurray81 merged 5 commits into
vnextfrom
btraykov/pr-build-ci

Conversation

@turbobobbytraykov

@turbobobbytraykov turbobobbytraykov commented Nov 11, 2026 •

Copy link
Copy Markdown
Contributor

Pull requests had no CI. build-and-deploy.yml runs only on pushes to vnext and main, so a PR that breaks the build is found only after it's merged. This adds PR build (pr-build.yml), which runs on pull requests to vnext and main. It also adds the iOS platform files the samples were missing, so that iOS can be built.

What it runs

  • build: the same Debug build on every platform. On each platform it builds the samples browser where it targets that platform, plus the standalone samples.
  • What it leaves out: anything that only a deployment needs. There's no AOT and no trimming (a build doesn't do either), no compression (DisableBuildCompression=true skips the .br/.gz copies), no artifact, no deployment and no secrets.
Platform Runner Samples browser Samples
browserwasm ubuntu-24.04 ✓ ✓
android ubuntu-24.04 ✓ ✓
desktop ubuntu-24.04 ✓ ✓
ios macos-15, simulator build (no signing); Xcode 16.4 for net9.0, 26.0.1 for net10.0 (doesn't target iOS) ✓
  • plan: reads the target framework from SamplesBrowser.csproj, so a framework change such as Move to .NET 10 (LTS), keeping Uno.Sdk 6.7.45 #18 moves the builds with it. It also picks the Xcode version for that framework and lists the samples.
    • Which samples: three from different packages (category chart, data grid, geo map), plus up to five that the PR changes. It logs a notice when the PR changes more.
    • All 331 samples share one project template, so three cover the build logic, and the samples browser compiles every sample's code.
  • checks: the two checks of the repository's own tools that the deploy build also runs: direct sample links, and the source-viewer self-test.

What only the deploy build covers, after a merge to vnext or main:

  • the AOT publish
  • trimming
  • the publish-time targets (documentation JSON, Open Sans subset, retiring service worker, gzip removal)
  • Validate deployable site

A PR that breaks one of those shows up in the vnext build after it's merged, which then doesn't deploy.

iOS platform files

The samples target net*-ios, but they had no Platforms/iOS folder, so iOS never built: Uno.Sdk looked for iOS/Info.plist. Each of the 331 samples and scripts/uno-template (which port-to-uno.ps1 copies into new samples) now has:

  • Info.plist, Entitlements.plist and Main.iOS.cs, taken from Uno.Templates 6.7.45. The entry point starts the app with UnoPlatformHostBuilder…UseAppleUIKit(), as Uno 6 apps do, and calls the samples' App.InitializeLogging().
  • Two deliberate differences from Uno's template:
    • UIRequiredDeviceCapabilities lists only arm64, since .NET for iOS is 64-bit only.
    • No PrivacyInfo.xcprivacy (only needed for App Store submission, and the template's copy isn't a well-formed privacy manifest) and no launch-image catalog (it names no images; the splash comes from Assets/Splash/splash_screen.svg).

Mac Catalyst can't be built yet

The samples also target net*-maccatalyst, but that can't link with Uno 6.7's Skia renderer:

  • Uno's Apple runtime, Uno.WinUI.Runtime.Skia.AppleUIKit 6.7.359, depends on Uno.icu-ios, for Mac Catalyst too. That package (77.3.2, and 77.4.1 as well) ships only iOS device and simulator libraries.
  • The result is ld: building for 'macCatalyst', but linking in object file (…/uno.icu-ios/77.3.2/…/libicuuc.a) built for 'iOS', on .NET 9 (an earlier run of this PR) and on .NET 10 (temporary draft [Temporary, do not merge] PR build on .NET 10 #22, now closed).
  • Uno's own 6.x project templates no longer include a Mac Catalyst folder. Uno.Templates 5.6.54 was the last one that did.

So the matrix leaves Mac Catalyst out, and the workflow comment says why. Files in this repository can't fix it. The options are to drop net*-maccatalyst from the samples' target frameworks (on macOS they run through the desktop target), or to keep it and ask Uno for a Mac Catalyst ICU build.

Notes

Results

Run 43006310901 on this PR (.NET 9) passed, with no artifact. It took about 14 minutes in all, since the jobs run in parallel.

Job Time
plan 7 s
checks 20 s
build (desktop) 1.6 min
build (browserwasm) 9.3 min
build (ios) 9.6 min
build (android) 13.7 min

On .NET 10, temporary draft #22 (#18 combined with an earlier version of this workflow) built every platform except Mac Catalyst.

🤖 Generated with Claude Code

PR build (pr-build.yml) runs on pull requests to vnext and main and deploys
nothing. It calls the build job of build-and-deploy.yml as a reusable workflow,
so a PR is checked with the same AOT publish and site validation that deploys,
and its dispatch job is skipped. A matrix then builds the samples browser for
android and desktop, and three samples (plus up to five the PR changes) for
android, desktop, browserwasm, ios and maccatalyst. The target framework is read
from SamplesBrowser.csproj, so the matrix follows a framework change.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The first run showed that the standalone samples list ios and maccatalyst but cannot build them: they have no Platforms/iOS or Platforms/MacCatalyst files (Info.plist is missing). The workflow comment says what to add before putting those platforms back.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The samples (and scripts/uno-template, which port-to-uno.ps1 copies) listed
net*-ios and net*-maccatalyst but had no Platforms/iOS or Platforms/MacCatalyst
folder, so those heads could not build (Uno.Sdk looked for iOS/Info.plist).
Each project now has Info.plist, Entitlements.plist and an entry point for both,
from Uno.Templates 6.7.45 (iOS) and 5.6.54 (Mac Catalyst, which the 6.x templates
no longer scaffold), both started with UnoPlatformHostBuilder.UseAppleUIKit().
The PR build matrix builds ios and maccatalyst again on macos-15.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
turbobobbytraykov and others added 2 commits November 11, 2026 12:26
The iOS files work: the samples build for net9.0-ios and net10.0-ios on macos-15.
Mac Catalyst does not link on either version: Uno.WinUI.Runtime.Skia.AppleUIKit 6.7
depends on Uno.icu-ios, which ships only iOS device and simulator libraries. That
is not something files in this repository can fix, so the Mac Catalyst files are
removed again and the matrix leaves maccatalyst out, with the reason next to it.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The WebAssembly build no longer calls build-and-deploy.yml (which brought its
skipped dispatch job, the AOT publish, the site validation and an artifact).
Every platform, browserwasm included, now runs the same Debug build of the
samples browser (where it targets that platform) and the samples, with build
compression disabled (DisableBuildCompression). The two tool checks run in their
own job. build-and-deploy.yml is back to its vnext version.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@gmurray81
gmurray81 merged commit 7b02c8d into vnext Nov 11, 2026
6 checks passed
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.

2 participants