Skip to content

ci: build, test and release the NuGet package with GitHub Actions - #445

Merged
NotYoojun merged 13 commits into
mainfrom
ci/nuget-release
Oct 28, 2026
Merged

NotYoojun merged 13 commits into
mainfrom
ci/nuget-release

Conversation

@NotYoojun

@NotYoojun NotYoojun commented Oct 22, 2026 •

Copy link
Copy Markdown
Member

Summary

  • Packaging: the NuGet package is now produced by msbuild -t:Pack from source/iNKORE.UI.WPF.Modern.nuspec instead of by hand. The layout is the same as 0.10.2.1 (net452, net6.0-windows10.0.18362, net6.0-windows7.0), with two fixes:

    • translations now work on .NET 6+ too; the hand-made package had none there, so those apps only got English. Resource.Embedder embeds them in the DLLs on every target, as it already did on .NET Framework, so consumers get no culture folders in their output;
    • iNKORE.UI.WPF.dll and System.ValueTuple.dll are no longer duplicated in lib/net452.
  • Versioning: the version comes from MSBuild. VersionPrefix in Directory.Build.props is used for local and CI builds; releases pass -p:Version from the tag. The iNKORE.UI.WPF version is set once, in Directory.Build.targets.

  • build.yml: runs on PRs (after approval on the pr-build environment), on v* tags and by hand. It builds the solution, packs, zips the Gallery and runs tests/Package:

    • checks on the package layout (including no culture folders), dependencies and versions;
    • WPF consumer apps on net8.0-windows, net8.0-windows10.0.19041.0 and net48, built with both dotnet build and MSBuild, then run. They check the zh-TW strings, and that the output has no culture folders.

    The nupkg and iNKORE.UI.WPF.Modern.Gallery@<version>.zip are uploaded unwrapped (archive: false), so each artifact downloads as the file itself.

  • release.yml: publishing a GitHub release for a v* tag, after approval on the nuget environment, pushes that tag build's nupkg to NuGet.org (Trusted Publishing) and attaches the nupkg and Gallery zip to the release.

  • Actions: every action is pinned to a commit SHA, with its version in a comment. Dependabot (.github/dependabot.yml) keeps them up to date in one grouped PR a week.

  • Resources: renamed the gd-gb / ca-Es-VALENCIA resx files to their standard culture casing, gd-GB and ca-ES-valencia.

Releasing

  1. Push a tag vX.Y.Z; Build runs automatically.
  2. Create the GitHub release for that tag, write the notes, publish.
  3. Approve the nuget deployment.

Notes

  • build.yml has passed on this PR. release.yml only runs when a release is published, so the first release will be its first run.
  • After merging, turn on Settings → Actions → "Require actions to be pinned to a full-length commit SHA".
  • Known issue, also in 0.10.2.1, to be fixed separately: apps on plain net*-windows resolve lib/net6.0-windows7.0, where the system accent and theme don't work, because the DLL needs Microsoft.Windows.SDK.NET.
  • NU5125 (licenseUrl) during pack is expected.

Tested locally:

  • pack, and the package contents compared against 0.10.2.1;
  • consumer apps on all three TFMs, built with dotnet build and MSBuild: the zh-TW strings load from the embedded resources, and no culture folders appear in the output;
  • the structure test rejects a package that still has culture folders.

Copilot AI balanced review requested due to automatic review settings October 22, 2026 13:04

This comment was marked as low quality.

@NotYoojun
NotYoojun merged commit 9ff5b0f into main Oct 28, 2026
3 checks passed
@NotYoojun
NotYoojun deleted the ci/nuget-release branch October 28, 2026 02:25
@NotYoojun
NotYoojun restored the ci/nuget-release branch October 28, 2026 03:06
@NotYoojun
NotYoojun deleted the ci/nuget-release branch October 28, 2026 03:07

This branch was successfully deployed

1 active deployment
pr-build — 0bc8a20d Deployed Oct 28, 2026 by NotYoojun via approve #960
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.

3 participants