microsoft/dotnet-framework-version-upgrade
> Upgrade .NET Framework projects to .NET Framework 4.8.1 (net481), staying on full .NET Framework without migrating to modern .NET (net8.0+). Use when user explicitly asks to upgrade to .NET Framework 4.8.1, upgrade to the latest .NET Framework version, or stay on full/Windows .NET Framework. Preserves legacy vs SDK-style project format unless the user explicitly requests SDK-style conversion.
npx skills add https://github.com/microsoft/upgrade-agent-plugins --skill dotnet-framework-version-upgrade
Upgrade .NET Framework projects from their current framework version (e.g., net472) to .NET Framework 4.8.1 (net481), staying on full .NET Framework.
Goal: Upgrade one or more .NET Framework projects to net481 while maintaining functionality. Preserve each project's existing project format: legacy projects stay legacy unless the user explicitly requests SDK-style conversion, and SDK-style projects stay SDK-style.
Target: Always net481 (.NET Framework 4.8.1) — the latest and final .NET Framework release.
When to use: User explicitly requests a .NET Framework version upgrade on Windows, asks to "stay on .NET Framework", "upgrade to 4.8.1", or "upgrade to latest .NET Framework".
When NOT to use: If the user wants to migrate to modern .NET (net8.0+), use the dotnet-version-upgrade scenario instead. If the user is invoking from a non-Windows platform, explain that this scenario is intended for Windows because full .NET Framework and its reference assemblies are Windows-only.
| Concern | dotnet-version-upgrade | This scenario |
|---------|------------------------|---------------|
| TFM XML | SDK: <TargetFramework>net8.0</TargetFramework> | Legacy: <TargetFrameworkVersion>v4.8.1</TargetFrameworkVersion>; SDK-style Framework projects use net481 |
| Build tool | dotnet build | msbuild |
| Package management | PackageReference + dotnet add package | packages.config + manual XML editing |
| SDK-style conversion | Mandatory first step | Not done by default — legacy vs SDK-style project format is preserved unless the user explicitly requests conversion |
| Planning | Strategies menu, side-by-side web, multi-targeting | Always All-at-Once or simple Bottom-Up |
| Options | 12 upgrade-option files evaluated | None — no configurable options |
Run these stages in order:
net481 (fixed — no options tool call), platform = Windows. Confirm which projects to upgrade. Consumed during pre-initialization by the scenario-initializer worker.generate_dotnet_upgrade_assessment. Focus on NuGet compatibility and minor API changes. Creates assessment.md.plan.md and scenario-instructions.md.TargetFrameworkVersion / TargetFramework(s), retarget packages.config metadata, build with msbuild (legacy) or dotnet build. Creates tasks/*/task.md and execution-log.md.This section is consumed during pre-initialization by the scenario-initializer worker. It defines the scenario-specific parameters and tools for this scenario.
Do not call get_dotnet_upgrade_options during pre-initialization; this scenario has a fixed target (net481) and that tool returns modern .NET targets.
Before continuing, check the current platform. If the agent is running on Linux, macOS, or another non-Windows platform, inform the user that this scenario is not intended for that environment because full .NET Framework 4.8.1 build validation depends on Windows reference assemblies and tooling. Do not start the assessment until the user switches to a Windows environment.
Confirm the project scope from the user's request or the loaded solution/project context. If all selected .NET Framework projects already target net481, inform the user and exit gracefully.
Include this in the consolidated prompt:
#### Target Framework
Upgrade to: **.NET Framework 4.8.1 (net481)**
Platform: **Windows required**
Project format: Preserve existing project format. Legacy projects remain legacy unless the user explicitly requests SDK-style conversion; SDK-style projects remain SDK-style.
dotnet-version-upgrade scenario instead.sdk-style-conversion / converting-to-sdk-style; do not manually rewrite project files in this scenario.scenario-instructions.md: targetFramework: net481, targetFrameworkVersion: v4.8.1.Load each stage's instructions file only when entering that stage.
When entering this stage, load: assessment.md *(read completely - contains 3 required steps)*
Analyzes selected .NET Framework projects and produces the assessment document:
When entering this stage, load: planning.md *(read completely - contains 3 required steps)*
Creates a fixed-target plan:
When entering this stage, load: execution.md *(read completely - contains 4 sections)*
Executes the plan while preserving existing project system:
<TargetFrameworkVersion> edits for legacy projects<TargetFramework> or <TargetFrameworks> edits for SDK-style projectsnet481 or v4.8.1, depending on project system).This scenario is intended for Windows only. Build validation requires the .NET Framework 4.8.1 Developer Pack/reference assemblies, which are Windows-specific. If validation fails with missing reference assemblies, install the Developer Pack before treating the upgrade as broken.
convert_project_to_sdk_style for the default Framework version upgrade path. Use it only when the user explicitly requested SDK-style conversion and that conversion was planned as separate scope.get_dotnet_upgrade_options — it returns only modern .NET targets.managing-legacy-dotnet-packages skill for package updates (not managing-package-references).Take microsoft/dotnet-framework-version-upgrade from the repository into ~/.claude/skills for personal
use, or into .claude/skills inside a project.
The agent identifies a skill by the name field in its header. Two skills with the
same name cannot sit side by side — one of them will be ignored.