Sponsor Suno AI Music arrow_forward
Subagent

.NET Upgrade

Perform janitorial tasks on C#/.NET code including cleanup, modernization, and tech debt remediation.

Type
Subagent
GitHub stars
39.4k
License
MIT
Repo last updated
Sep 27, 2026

What .NET Upgrade is

.NET Upgrade is a subagent published in the github/awesome-copilot repository on GitHub, which has about 39.4k stars. The repository describes itself as: “Community-contributed instructions, agents, skills, and configurations to help you make the most of GitHub Copilot.”

A subagent is a specialist assistant that Claude can hand part of a task to. It is a markdown file whose frontmatter sets a name, a description that tells Claude when to delegate, and optionally the tools and model it may use; the body becomes the subagent's own system prompt.

Because a subagent works in its own context, it keeps the main conversation focused: Claude can send a narrow job, such as a review or a specialised analysis, to .NET Upgrade and get back a compact result.

It is set up to use these tools: 'codebase', 'edit/editFiles', 'search', 'runCommands', 'runTasks', 'runTests', 'problems', 'changes', 'usages', 'findTestFiles', 'testFailure', 'terminalLastCommand'. Limiting tools is a good sign: the subagent can only do what those tools allow.

How to install .NET Upgrade

Claude Code

  1. Download dotnet-upgrade.agent.md from the repository.
  2. Save it to ~/.claude/agents/ to use it in every project, or to .claude/agents/ inside one project to share it through version control.
  3. Claude Code watches these folders, so the subagent is usually available right away. Ask Claude to use it by name, or @-mention it to make sure it runs.

Claude Cowork

  1. Cowork loads subagents through plugins. If the repository is packaged as a plugin marketplace, add it under Customize → Plugins → Add marketplace and install the plugin that contains this subagent.
  2. Otherwise, bundle the file into your own plugin's agents/ folder and upload it from Customize → Plugins.

New to extending Cowork? Our plugins guide and Customize guide explain how skills, plugins, and connectors fit together.

Inside the source file

An excerpt from agents/dotnet-upgrade.agent.md, shared under the repository's MIT license. Read the full file on GitHub.

.NET Framework upgrade specialist for comprehensive project migration

Tags: dotnet, upgrade, migration, framework, modernization

Collection Usage

.NET Upgrade Chat Mode

Discover and plan your .NET upgrade journey!

---
mode: dotnet-upgrade
title: Analyze current .NET framework versions and create upgrade plan
---
Analyze the repository and list each project's current TargetFramework
along with the latest available LTS version from Microsoft's release schedule.
Create an upgrade strategy prioritizing least-dependent projects first.

The upgrade chat mode automatically adapts to your repository's current .NET version and provides context-aware upgrade guidance to the next stable version.

It will help you:

  • Auto-detect current .NET versions across all projects
  • Generate optimal upgrade sequences
  • Identify breaking changes and modernization opportunities
  • Create per-project upgrade flows

.NET Upgrade Instructions

Execute comprehensive .NET framework upgrades with structured guidance!

The instructions provide:

  • Sequential upgrade strategies
  • Dependency analysis and sequencing
  • Framework targeting and code adjustments
  • NuGet and dependency management
  • CI/CD pipeline updates
  • Testing and validation procedures

Use these instructions when implementing upgrade plans to ensure proper execution and validation.

.NET Upgrade Prompts

Quick access to specialized upgrade analysis prompts!

The prompts collection includes ready-to-use queries for:

  • Project discovery and assessment
  • Upgrade strategy and sequencing
  • Framework targeting and code adjustments
  • Breaking change analysis
  • CI/CD pipeline updates
  • Final validation and delivery

Use these prompts for targeted analysis of specific upgrade aspects.

Quick Start

  1. Run a discovery pass to enumerate all .sln and .csproj files in the repository.
  2. Detect the current .NET version(s) used across projects.
  3. Identify the latest available stable .NET version (LTS preferred) — usually +2 years ahead of the existing version.
  4. Generate an upgrade plan to move from current → next stable version (e.g., net6.0 → net8.0, or net7.0 → net9.0).
  5. Upgrade one project at a time, validate builds, update tests, and modify CI/CD accordingly.

Auto-Detect Current .NET Version

To automatically detect the current framework versions across the solution:

# 1. Check global SDKs installed
dotnet --list-sdks

# 2. Detect project-level TargetFrameworks
find . -name "*.csproj" -exec grep -H "<TargetFramework" {} \;

# 3. Optional: summarize unique framework versions
grep -r "<TargetFramework" **/*.csproj | sed 's/.*<TargetFramework>//;s/<\/TargetFramework>//' | sort | uniq

# 4. Verify runtime environment
dotnet --info | grep "Version"

Chat Prompt: > "Analyze the repository and list each project’s current TargetFramework along with the latest available LTS version from Microsoft’s release schedule."

Discovery & Analysis Commands

# List all projects
dotnet sln list

# Check current target frameworks for each project
grep -H "TargetFramework" **/*.csproj

# Check outdated packages
dotnet list <ProjectName>.csproj package --outdated

# Generate dependency graph
dotnet msbuild <ProjectName>.csproj /t:GenerateRestoreGraphFile /p:RestoreGraphOutputPath=graph.json

Chat Prompt: > "Analyze the solution and summarize each project’s current TargetFramework and suggest the appropriate next LTS upgrade version."

Classification Rules

  • TargetFramework starts with netcoreapp, net5.0+, net6.0+, etc. → Modern .NET
  • netstandard* → .NET Standard (migrate to current .NET version)
  • net4* → .NET Framework (migrate via intermediate step to .NET 8+)

Upgrade Sequence

  1. Start with Independent Libraries: Least dependent class libraries first.
  2. Next: Shared components and common utilities.
  3. Then: API, Web, or Function projects.
  4. Finally: Tests, integration points, and pipelines.

Chat Prompt: > "Generate the optimal upgrade order for this repository, prioritizing least-dependent projects first."

Before you install

  • Read the whole file first. Skills, commands, and subagents are instructions Claude will follow, so make sure they match what you want.
  • Check which tools, scripts, or MCP servers it uses. Local servers and scripts run with your permissions.
  • Try it in a test project or a copy of your files before pointing it at real work.
  • Pin the version you tested, and review changes before updating.
  • Watch for instructions that fetch web content or run shell commands; those are where prompt injection risks start. See our prompt injection guide.

FAQ

What is .NET Upgrade?

.NET Upgrade is a subagent for Claude Code and Claude Cowork from the github/awesome-copilot repository on GitHub. Perform janitorial tasks on C#/.NET code including cleanup, modernization, and tech debt remediation.

How do I install .NET Upgrade in Claude Code?

Download dotnet-upgrade.agent.md from the repository. Save it to ~/.claude/agents/ to use it in every project, or to .claude/agents/ inside one project to share it through version control. Claude Code watches these folders, so the subagent is usually available right away. Ask Claude to use it by name, or @-mention it to make sure it runs.

Can I use .NET Upgrade in Claude Cowork?

Cowork loads subagents through plugins. If the repository is packaged as a plugin marketplace, add it under Customize → Plugins → Add marketplace and install the plugin that contains this subagent. Otherwise, bundle the file into your own plugin's agents/ folder and upload it from Customize → Plugins.

Is .NET Upgrade safe to install?

It is a third-party community resource, not reviewed by Anthropic or this site. Read the source file first, check which tools and connectors it uses, and install only from sources you trust.

Similar resources

Browse all skills, subagents, and plugins →

Listing data comes from the public GitHub repository and was last checked in September 2026. Excerpts are © their authors and shared under MIT. This directory is independent and not affiliated with Anthropic or the resource's authors.