Convert to two-phase dual-publish release model - #320
Merged
Conversation
Replace publish-on-push with the ProjectTemplate/LanguageTags two-phase model: PRs smoke-test only, and publish-release.yml publishes both branches on a weekly schedule (Mon 02:00 UTC) or manual dispatch, with idempotent no-op republish. Adopt the reusable workflow set (get-version, build-nugetlibrary, build-release, build-datebadge), a branch-aware Dependabot merge-bot, Central Package Management, and an AGENTS.md tracking the template. NuGet.org-only (drop GitHub Packages); no Docker/exe/PyPI/codegen. Reconcile the template's strict analyzers (AnalysisMode All + TreatWarningsAsErrors) with the brownfield library by relaxing specific rules in .editorconfig and IL3058 via NoWarn, all documented.
Convert the workflow YAML, dependabot.yml, and AGENTS.md (added LF) to CRLF per .editorconfig, and make .husky/pre-commit LF + executable so its shebang execs on Linux/WSL. Add an .editorconfig rule pinning the hook to LF.
Contributor
There was a problem hiding this comment.
Pull request overview
Migrates the repository’s CI/CD from the previous publish-on-push pipeline to the ProjectTemplate-aligned two-phase dual-publish model (PR smoke-test only; scheduled/manual publish of both main and develop), while introducing Central Package Management and codifying release/workflow conventions.
Changes:
- Replaces the legacy build/publish workflows with a reusable-task workflow set, a PR-only test/smoke workflow, and a scheduled/manual publisher that can optionally publish on merge via
PUBLISH_ON_MERGE. - Introduces Central Package Management (
Directory.Build.props,Directory.Packages.props) and adjusts project files/using directives to rely on shared settings + implicit usings. - Adds/updates repo process documentation and configuration (
AGENTS.md,.editorconfig, hook shebang/line-endings,.gitignore, README badge).
Reviewed changes
Copilot reviewed 38 out of 40 changed files in this pull request and generated 4 comments.
Show a summary per file
| File | Description |
|---|---|
| UtilitiesTests/UtilitiesTests.csproj | Removes per-project TFM/analyzer/version pinning to rely on shared build props + central package versions. |
| UtilitiesTests/UtilitiesTests.cs | Removes redundant explicit using now covered by implicit usings. |
| UtilitiesTests/StringHistoryTests.cs | Removes redundant explicit using now covered by implicit usings. |
| UtilitiesTests/StringCompressionTests.cs | Removes redundant explicit using now covered by implicit usings. |
| UtilitiesTests/StringCompressionAsyncTests.cs | Removes redundant explicit using now covered by implicit usings. |
| UtilitiesTests/FileExAsyncTests.cs | Removes redundant explicit using now covered by implicit usings. |
| UtilitiesTests/ExtensionsTests.cs | Updates null-argument extension tests and removes redundant usings as part of analyzer/implicit-using cleanup. |
| UtilitiesTests/DownloadTests.cs | Removes redundant explicit using now covered by implicit usings. |
| UtilitiesTests/DownloadAsyncTests.cs | Removes redundant explicit using now covered by implicit usings. |
| UtilitiesTests/ConsoleTests.cs | Removes redundant explicit using now covered by implicit usings. |
| Utilities/Utilities.csproj | Moves analyzer/TFM/nullable to shared props; adds AOT warning suppression for IL3058; uses CPM. |
| Utilities/StringHistory.cs | Removes redundant explicit using now covered by implicit usings. |
| Utilities/StringCompression.cs | Removes redundant explicit using now covered by implicit usings. |
| Utilities/Format.cs | Removes redundant explicit using now covered by implicit usings. |
| Utilities/FileExOptions.cs | Removes redundant explicit using now covered by implicit usings. |
| Utilities/FileEx.cs | Removes redundant explicit using now covered by implicit usings. |
| Utilities/Extensions.cs | Removes redundant explicit using now covered by implicit usings. |
| Utilities/Download.cs | Removes redundant explicit using now covered by implicit usings. |
| Utilities/ConsoleEx.cs | Removes redundant explicit using now covered by implicit usings. |
| Utilities/CommandLineEx.cs | Removes redundant explicit using now covered by implicit usings. |
| Utilities.slnx | Adds new solution items for CPM + agent/process docs + new workflows; removes legacy workflow entries. |
| Sandbox/Sandbox.csproj | Aligns sandbox build props with shared settings + CPM; suppresses IL3058 similarly. |
| Sandbox/Program.cs | Minor cleanup to use AppContext and rely on implicit usings. |
| README.md | Updates workflow-status badge to point at the new publisher workflow. |
| Directory.Packages.props | Adds central package version definitions for NuGet, tests, and Serilog dependencies. |
| Directory.Build.props | Adds shared build settings (TFM, analyzers, WarningsAsErrors, artifacts path, CPM enablement). |
| AGENTS.md | Documents branching rules, release model, and workflow conventions for maintainers/agents. |
| .husky/pre-commit | Normalizes shebang/line-endings to ensure hook runs on POSIX shells. |
| .gitignore | Ignores .artifacts folder produced by the shared ArtifactsPath. |
| .github/workflows/test-pull-request.yml | New PR workflow: unit tests + paths-filter-gated smoke build + required-status aggregator job. |
| .github/workflows/publish-release.yml | New publisher: scheduled/manual dual-branch publish, optional push-publish gated by PUBLISH_ON_MERGE. |
| .github/workflows/merge-bot-pull-request.yml | New Dependabot merge-bot using App token and branch-aware merge method. |
| .github/workflows/get-version-task.yml | New reusable workflow to compute NBGV version metadata with a pinned checkout ref. |
| .github/workflows/build-release-task.yml | New reusable orchestrator tying versioning, NuGet build/push, and GitHub release creation together. |
| .github/workflows/build-nugetlibrary-task.yml | New reusable NuGet build/push + artifact upload task, branch-config aware. |
| .github/workflows/build-datebadge-task.yml | New reusable BYOB badge task gated to main. |
| .github/workflows/DependabotAutoMerge.yml | Removes legacy Dependabot auto-merge workflow in favor of merge-bot model. |
| .github/workflows/BuildPublishPipeline.yml | Removes legacy publish-on-push pipeline in favor of two-phase model. |
| .github/dependabot.yml | Updates Dependabot config to open updates against both main and develop. |
| .editorconfig | Adds LF override for husky hook + documents analyzer relaxations for brownfield code under strict analysis mode. |
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
This was referenced Jun 5, 2026
ptr727 added a commit
that referenced
this pull request
Jun 5, 2026
## Summary Land the two-phase dual-publish model on `main`, with **fully signed & GitHub-verified history**. This is `main` merged with `develop` (`0f1616d`), the one-time old→new structural conflicts resolved in **develop's favour**, and the **max dependency/tool versions** taken so `main`'s newer Dependabot bumps are not regressed. All introduced commits are committer = `Pieter Viljoen <ptr727@users.noreply.github.com>` and verified, satisfying `required_signatures` (supersedes #322/#323, which carried unverifiable web-flow-committed history). ### Dependency reconciliation (max of develop/main) | Package / tool | Version | | --- | --- | | Microsoft.SourceLink.GitHub | 10.0.201 | | Serilog | 4.3.1 | | Microsoft.NET.Test.Sdk | 18.4.0 | | xunit.analyzers | 1.27.0 | | csharpier (tool) | 1.2.6 | | husky (tool) | 0.9.1 | Net diff vs `develop` is only the six version bumps above. See #320 for the full change description. ## Maintainer follow-ups (after merge) - Add `CODEGEN_APP_CLIENT_ID` / `CODEGEN_APP_PRIVATE_KEY` (GitHub App) to **both** Actions and Dependabot secret stores for the merge-bot. - Let Dependabot bring `develop`'s deps up to match (or open a small sync PR). - Kick off the first publish via **Actions → publish-release.yml → Run workflow** once secrets are in. 🤖 Generated with [Claude Code](https://claude.com/claude-code)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for freeto join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Convert the project from publish-on-push to the ptr727/ProjectTemplatetwo-phase dual-publish release model, matching the structure already adopted by
LanguageTagsso future template changes apply as minimal deltas.test-pull-request.ymlruns unit tests + a paths-filtered smoke build; merges no longer publish.publish-release.ymlpublishes both branches on a Monday 02:00 UTC cron and on manual dispatch, with idempotent no-op republish (skip release if the tag exists,--skip-duplicateon NuGet). Opt-in continuous-release via thePUBLISH_ON_MERGErepo variable.Changes
get-version-task,build-nugetlibrary-task,build-release-task,build-datebadge-task, pluspublish-release,test-pull-request, and a branch-aware Dependabotmerge-bot-pull-request(squash on develop / merge on main).BuildPublishPipeline.ymlandDependabotAutoMerge.yml. NuGet.org-only (dropped the GitHub Packages push). No Docker/executable/PyPI/codegen targets.Directory.Build.props+Directory.Packages.props).AGENTS.mddocumenting the branching/release/workflow conventions.AnalysisMode All+TreatWarningsAsErrors) with this brownfield library by relaxing specific rules in.editorconfig(each documented inline) andIL3058viaNoWarn;ImplicitUsingscleanup removed now-redundant usings..editorconfigand fixed the.husky/pre-commitshebang to LF + executable.Maintainer follow-ups (not in this PR)
CODEGEN_APP_CLIENT_ID/CODEGEN_APP_PRIVATE_KEY(GitHub App) to both Actions and Dependabot secret stores for the merge-bot.Check pull request workflow statusrequired check to thedevelop(squash-only) andmain(merge-only) rulesets.PUBLISH_ON_MERGEunset for the two-phase default.🤖 Generated with Claude Code