msbuild-server

Configure MSBuild Server to cache build evaluations across CLI builds.

1|Updated Jun 1, 2026
One-click install
npx skills add https://github.com/D1ssolve/craft-agents --skill msbuild-server-d1ssolve
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: msbuild-server
Source: https://github.com/D1ssolve/craft-agents/tree/main/skills/msbuild-server
Command: npx skills add https://github.com/D1ssolve/craft-agents --skill msbuild-server-d1ssolve

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? Command-line .NET builds restart MSBuild on every invocation, losing cached evaluation results and making incremental builds slower than Visual Studio builds. This Skill guides you through enabling the MSBuild Server so CLI builds reuse a persistent process with cached state. ## Core Features & Use Cases - Environment Variable Setup: Set MSBUILDUSESERVER=1 in bash, PowerShell, or persistently on Windows to enable server-based caching. - Build Validation Workflow: Compare cold and warm sequential builds to confirm the performance improvement. - Server Lifecycle Management: Reset or shut down the server with dotnet build-server shutdown when troubleshooting. - Use Case: A CI agent runs many sequential builds of a large multi-project repo; enabling the MSBuild Server makes each warm build noticeably faster by reusing cached evaluation results. ## Quick Start Enable the MSBuild Server for my command-line dotnet builds and verify that the second build runs faster than the first.

Frequently Asked Questions about msbuild-server

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I speed up dotnet build from the command line?

Set the MSBUILDUSESERVER=1 environment variable to enable the MSBuild Server, which caches evaluation results across builds. Run two sequential builds and compare times; the second warm build should be noticeably faster.

How do I enable MSBuild Server in PowerShell or bash?

In bash run export MSBUILDUSESERVER=1, in PowerShell run $env:MSBUILDUSESERVER = "1", and on Windows use setx MSBUILDUSESERVER 1 for a persistent setting. The variable must be set in the shell where dotnet build runs.

Does MSBuild Server help builds inside Visual Studio?

No, Visual Studio already uses a long-lived MSBuild process with cached state, so the server adds no benefit for IDE builds. It only improves command-line builds where MSBuild would otherwise restart on every invocation.

Why did my build behave incorrectly after enabling MSBuild Server?

Cached state can occasionally cause unexpected behavior. Run dotnet build-server shutdown to reset the server, and if issues persist, disable the server by unsetting MSBUILDUSESERVER to isolate the problem.

When should I not use MSBuild Server?

Avoid it for IDE-based builds, one-off builds where cold-start overhead is acceptable, and when diagnosing build correctness issues. The persistent server also holds memory in the background, so shut it down when idle.