Skip to content

Build with dotnet build - #58

Open
xperiandri wants to merge 6 commits into
mrlacey:mainfrom
xperiandri:chain/dotnet-build
Open

xperiandri wants to merge 6 commits into
mrlacey:mainfrom
xperiandri:chain/dotnet-build

Conversation

@xperiandri

@xperiandri xperiandri commented Oct 27, 2026 •

Copy link
Copy Markdown

Summary

Stacked on #57. The branch contains the commits of #57 and of the pull requests before it, so the last 1 commit is new here.

This pull request builds the solution with dotnet build instead of the MSBuild of Visual Studio in the build workflow. It requires #55: the SDK-style projects build with the .NET SDK, the old-style ones relied on the VSSDK targets that Visual Studio installs. It sits behind #57 only for the order of the commits. The same change in copilot-setup-steps.yml and the instructions are part of the last pull request of the chain (#69), because those files come with #54. The code does not change.

Chain, changes, things to know and verification

Chain

This pull request is part of a chain of small pull requests that all target main. After #53 the chain has two branches that do not depend on each other: the AI agent files (#54) and the modernization of the build (#55 to #58). The last pull request (#69) merges both and updates the instructions, which live in the files of the AI branch. The branch of each pull request contains the commits of the ones it is stacked on, so GitHub lists those commits here until they are merged. Merge in this order and review only the commits that are new in each pull request:

  1. Switch the solution to the .slnx format #53 – Switch the solution to the .slnx format (first in the chain, no dependencies)
  2. Add instructions, skills and MCP configuration for AI coding agents #54 – Add instructions, skills and MCP configuration for AI coding agents (stacked on Switch the solution to the .slnx format #53)
  3. Convert the projects to the SDK style #55 – Convert the projects to the SDK style (stacked on Switch the solution to the .slnx format #53)
  4. Move the package versions to central package management #56 – Move the package versions to central package management (stacked on Convert the projects to the SDK style #55)
  5. Set the C# language version to 14 #57 – Set the C# language version to 14 (stacked on Move the package versions to central package management #56)
  6. Build with dotnet build #58 – Build with dotnet build (stacked on Set the C# language version to 14 #57) – this pull request
  7. Update the instructions for the SDK-style projects, central package management, C# 14 and dotnet build #69 – Update the instructions for the SDK-style projects, central package management, C# 14 and dotnet build (stacked on Build with dotnet build #58 and Add instructions, skills and MCP configuration for AI coding agents #54)

Changes

  • .github/workflows/build.yaml runs dotnet build ./StringResourceVisualizer.slnx --configuration ${{ env.Configuration }} -p:OutDir=\_built -v:m; the step that made MSBuild available (timheuer/bootstrap-dotnet with msbuild: 'true') is gone. The version stamp, the artifact upload and the test steps are unchanged.

Things to know

  • dotnet build works for this repository because the SDK-style projects use no private Visual Studio assemblies, no COM references and no binary resources. It needs the .NET SDK 9.0.200 or later for the .slnx; the language version asks for 10 anyway.
  • The deployment to the Experimental instance is Visual Studio's job (F5).

Verification

  • dotnet build with the .NET SDK 10.0.402 and the MSBuild of Visual Studio 2026 give the same result in Debug and Release: the same VSIX entries and sizes, identical extension.vsixmanifest, pkgdef and content types, identical assembly fingerprints, the same 26 distinct warnings, and the 4 tests pass.
  • CI: the workflows of this repository wait for the approval of a maintainer on a pull request from a fork, so the commit ran in a fork on a clean windows-2022 runner: Build builds the solution with dotnet build and runs the 4 tests, which pass. As on the unchanged main (run), the step Publish Test Results fails there: the third-party action EnricoMi/publish-unit-test-result-action finds no Python interpreter on the image. This pull request neither causes nor changes it.

🤖 Generated with Claude Code

`dotnet sln migrate` produced `StringResourceVisualizer.slnx` from `StringResourceVisualizer.sln`, and the old file is removed. The projects and the solution items are the same. The project ids are the ones of the old solution, which is what Visual Studio writes into the file itself. The `.slnx` format is XML, much shorter than the `.sln`, and designed to reduce merge conflicts (https://devblogs.microsoft.com/visualstudio/new-simpler-solution-file-format/).

Building it needs the .NET SDK 9.0.200 or later, or MSBuild from Visual Studio or Build Tools 17.13 or later.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
xperiandri and others added 5 commits October 29, 2026 00:51
Both projects use `Microsoft.NET.Sdk` with `net481` now, and `VSSDKBuildToolsAutoSetup` with `Microsoft.VSSDK.BuildTools` 18.5 builds the VSIX. The source files are included by globbing; the extension project excludes the folder of the test project, which lies inside its own folder. `Properties\AssemblyInfo.cs` stays, because the version comes from the `Vsix` constants, and the output stays in `bin\Debug\` and `bin\Release\`.

The signing target is called `SignAndCopyVsix` and runs after `Build`. As `AfterBuild` it would be replaced by the SDK targets and never run.

The packages and their versions are the same, apart from the added `Microsoft.VSSDK.BuildTools`.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Visual Studio 2026 18.5 and later deploys an SDK-style VSIX project to the Experimental instance on F5 only when the solution has a `<Deploy>` element for it.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
`Directory.Packages.props` holds the version of each of the 19 packages, and the two projects name the packages only. The versions are the ones the projects had, so the resolved packages (154 for the extension, 162 for the tests) are the same as before.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
`Directory.Build.props` sets `LangVersion` to 14.0 for both projects; it was 12.0. A development machine needs the .NET SDK 10 or Visual Studio 2026 for it. The code compiles to the same types and methods as with 12.0, with the same warnings.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
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