Skip to content

feat!: target net10.0 and net11.0, drop net8.0 and net9.0 - #24

Merged
solrevdev merged 3 commits into
masterfrom
chore/net10-net11
Nov 12, 2026
Merged

solrevdev merged 3 commits into
masterfrom
chore/net10-net11

Conversation

@solrevdev

@solrevdev solrevdev commented Nov 12, 2026 •

Copy link
Copy Markdown
Owner

What changed

  • src/solrevdev.seedfolder.csproj: targets net10.0, plus net11.0 when the SDK is 11.0 or later (was net8.0;net9.0;net10.0). RollForward stays Major. Version bumped 1.6.2 to 1.7.0. Package description and release notes now name .NET 10 and .NET 11 only.
  • global.json (new): { "sdk": { "version": "10.0.100", "rollForward": "latestMajor", "allowPrerelease": false } }.
  • .github/workflows/ci.yml: setup-dotnet installs 10.0.x and 11.0.x explicitly. Integration tests run once per target framework.
  • .github/workflows/ci.yml: a new check package targets step runs right after dotnet pack. It fails the run if the nupkg lacks tools/net10.0/ or tools/net11.0/. It runs before the NuGet login, publish and tag steps.
  • tests/integration-test.sh and tests/integration-test.ps1: take the target framework as an argument (default net10.0). They hardcoded net8.0, so CI would have failed after this change.
  • AGENTS.md, .github/copilot-instructions.md, README.md, .vscode/launch.json: name net10.0 and net11.0 only and describe the SDK policy. README "Run tests" now points at the integration scripts, since there is no dotnet test project.

Why

On 11 Nov 2026 John decided the project follows supported .NET versions only: tools and tests target net10.0;net11.0, and nothing targets 8 or 9. .NET 8 and .NET 9 left support on 10 Nov 2026.

SDK policy

.NET 10 is the LTS and the baseline.

  • global.json pins SDK 10.0.100 with rollForward: latestMajor, so the newest installed release SDK is used.
  • Only SDK 11: builds and works (latestMajor picks 11).
  • SDK 10 and 11: uses 11 and builds both targets.
  • Only SDK 10: builds and works, net10.0 only.

Conditional target

<!-- The published package needs both targets; CI installs both SDKs so it ships both, and SDK 10 alone builds net10.0 only. -->
<TargetFrameworks>net10.0</TargetFrameworks>
<TargetFrameworks Condition="$([MSBuild]::VersionGreaterThanOrEquals('$(NETCoreSdkVersion)', '11.0'))">net10.0;net11.0</TargetFrameworks>

CI installs both SDKs, so latestMajor selects SDK 11 there and the published package always holds tools/net10.0 and tools/net11.0.

Package target check

The targets in the package depend on the SDK that built it. This step stops a release that would ship without one:

set -euo pipefail
# The targets depend on the SDK that built them; fail rather than
# ship a package missing one.
version=$(sed -n 's:.*<Version>\(.*\)</Version>.*:\1:p' src/solrevdev.seedfolder.csproj)
# Name the exact file: a glob would also match the symbols package,
# and unzip reads any extra argument as a member filter.
LISTING=$(unzip -l "src/nupkg/solrevdev.seedfolder.${version}.nupkg")
for tfm in net10.0 net11.0; do
  grep -q "tools/$tfm/any/solrevdev.seedfolder.dll" <<<"$LISTING" \
    || { echo "Package is missing tools/$tfm" >&2; exit 1; }
done

Step order: build, integration tests (net10.0), integration tests (net11.0), pack, check package targets, verify versioned package, NuGet login, publish. tag-release runs only after publish succeeds.

I extracted the step script from ci.yml and ran it locally against CI-style packs:

  • SDK 11.0.100, fresh build and pack: the package holds tools/net10.0/any/solrevdev.seedfolder.dll and tools/net11.0/any/solrevdev.seedfolder.dll. The check passed with exit 0.
  • Scratch worktree pinned to SDK 10.0.404 with rollForward: disable: the package holds only tools/net10.0/any/solrevdev.seedfolder.dll. The check failed with exit 1 and printed Package is missing tools/net11.0. The worktree was removed afterwards.

Install compatibility

Dropping net8.0 and net9.0 means a machine with only the .NET 8 or .NET 9 runtime can no longer install new releases. Those users must install .NET 10 or later, or stay on 1.6.2. This is why the first commit is marked feat!. The version bump is minor per John's call.

Merging may publish to NuGet

CI publishes to NuGet on push to master and then tags v1.7.0. Merging this PR will likely release 1.7.0, so merging is John's call. This PR has not been merged.

Verification

Local macOS machine with SDKs 10.0.404 and 11.0.100 and runtimes 10.0.15 and 11.0.0. No global tool, SDK or runtime was changed.

(a) Normal run: SDK 11 via latestMajor

$ dotnet --version
11.0.100

$ dotnet build solrevdev.seedfolder.sln -c Release
  solrevdev.seedfolder -> .../src/bin/Release/net10.0/solrevdev.seedfolder.dll
  solrevdev.seedfolder -> .../src/bin/Release/net11.0/solrevdev.seedfolder.dll
    0 Warning(s)
    0 Error(s)
Script net10.0 net11.0
tests/integration-test.sh <tfm> pass, 18 checks, 0 failures pass, 18 checks, 0 failures
tests/integration-test.ps1 -Framework <tfm> pass, 17 checks, 0 failures pass, 17 checks, 0 failures
$ dotnet pack solrevdev.seedfolder.sln -c Release -o <scratch>/a/nupkg
  Successfully created package '<scratch>/a/nupkg/solrevdev.seedfolder.1.7.0.nupkg'.

$ unzip -l solrevdev.seedfolder.1.7.0.nupkg   (tools/ folders)
tools/net10.0
tools/net11.0

(b) SDK 10 only

A scratch git worktree with global.json set to {"sdk":{"version":"10.0.404","rollForward":"disable"}}. That pin was not committed, and the worktree was removed afterwards.

$ dotnet --version
10.0.404

$ dotnet build solrevdev.seedfolder.sln -c Release
  solrevdev.seedfolder -> .../src/bin/Release/net10.0/solrevdev.seedfolder.dll
    0 Warning(s)
    0 Error(s)

Only net10.0 was built. Forcing -f net11.0 fails with NETSDK1045 as expected, which shows the condition is what keeps SDK 10 builds working.

Script net10.0
tests/integration-test.sh net10.0 pass, 18 checks, 0 failures
tests/integration-test.ps1 -Framework net10.0 pass, 17 checks, 0 failures
$ unzip -l solrevdev.seedfolder.1.7.0.nupkg   (tools/ folders)
tools/net10.0

$ dotnet tool install --tool-path <scratch>/b/tools --add-source <scratch>/b/nupkg solrevdev.seedfolder --version 1.7.0
Tool 'solrevdev.seedfolder' (version '1.7.0') was successfully installed.

$ <scratch>/b/tools/seedfolder --version
▲   seedfolder version 1.7.0+d5e67f2becfc751c0d50f276632a9d28d36acb5b

(c) Install the package from (a)

$ dotnet tool install --tool-path <scratch>/c/tools --add-source <scratch>/a/nupkg solrevdev.seedfolder --version 1.7.0
Tool 'solrevdev.seedfolder' (version '1.7.0') was successfully installed.

$ <scratch>/c/tools/seedfolder --version
▲   seedfolder version 1.7.0+d5e67f2becfc751c0d50f276632a9d28d36acb5b

Installed tools/ folders:
.store/solrevdev.seedfolder/1.7.0/solrevdev.seedfolder/1.7.0/tools/net10.0
.store/solrevdev.seedfolder/1.7.0/solrevdev.seedfolder/1.7.0/tools/net11.0

🤖 Generated with Claude Code

https://claude.ai/code/session_014Mjr3bTLWVmY8sc2j5bcqH

solrevdev and others added 3 commits November 12, 2026 11:15
Follow supported .NET versions only. .NET 8 and .NET 9 left support on
10 November 2026.

- Set TargetFrameworks to net10.0;net11.0 and keep RollForward Major.
- CI installs the 10.0.x and 11.0.x SDKs only and runs the integration
  tests once per target framework.
- Integration scripts take the target framework as an argument
  (default net10.0) instead of hardcoding net8.0.
- Update AGENTS.md, copilot instructions, README, launch.json and the
  package description and release notes.
- Bump version to 1.7.0.

BREAKING CHANGE: a machine with only the .NET 8 or .NET 9 runtime can no
longer install new releases. Install .NET 10 or later, or stay on 1.6.2.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_014Mjr3bTLWVmY8sc2j5bcqH
- Add global.json: SDK 10.0.100, rollForward latestMajor, no
  prereleases. .NET 10 LTS is the baseline and the newest installed
  SDK is used.
- Build net11.0 only when the SDK is 11.0 or later, so a machine with
  only SDK 10 still builds and runs net10.0. CI installs both SDKs, so
  the published package keeps both targets.
- Document the SDK policy in README, AGENTS.md and copilot instructions.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_014Mjr3bTLWVmY8sc2j5bcqH
The package targets depend on the SDK that built them. If CI ever
builds with SDK 10 alone, the nupkg ships without net11.0. Check that
tools/net10.0 and tools/net11.0 are both present right after pack,
before the NuGet login, publish and tag steps.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_014Mjr3bTLWVmY8sc2j5bcqH
@solrevdev
solrevdev merged commit ea0cd9b into master Nov 12, 2026
2 checks passed
@solrevdev
solrevdev deleted the chore/net10-net11 branch November 12, 2026 11:35
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