-
Notifications
You must be signed in to change notification settings - Fork 6.1k
Add docs for dotnet migration support for copilot cli and coding agent #49730
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from 2 commits
Commits
Show all changes
13 commits
Select commit
Hold shift + click to select a range
43a659c
add dotnet support for Copilot CLI
83029c4
add dotnet summary for Copilot CLI
b5fb4fe
update dotnet cli doc
7bc4367
refine the doc
c583ca0
Add .net migration mcp server for coding agent
ninpan-ms 2a95d37
Merge pull request #1 from hellosnow/ninpan/coding-agent
hellosnow d8f5181
update
alexwolfmsft 446ee03
edit pass
alexwolfmsft 89bf04e
edit pass
alexwolfmsft 39cdb04
edit pass
alexwolfmsft b180203
fix
alexwolfmsft c59885a
fixes
alexwolfmsft d0f8f0c
toc
alexwolfmsft File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,88 @@ | ||
| --- | ||
| title: Migrate .NET Apps to Azure Using GitHub Copilot App Modernization in Copilot CLI | ||
| description: Provides an overview of how .NET developers can migrate applications to Azure using GitHub Copilot App Modernization in the Copilot CLI. | ||
| ms.topic: concept-article | ||
| ms.custom: devx-track-dotnet | ||
| ms.date: 11/11/2025 | ||
| author: alexwolfmsft | ||
| ms.author: alexwolf | ||
| ms.reviewer: jessiehuang | ||
| --- | ||
|
|
||
| # Migrate .NET Apps to Azure Using GitHub Copilot App Modernization in Copilot CLI | ||
|
|
||
| ## Overview | ||
|
|
||
| This article provides an overview of how .NET developers can migrate their applications to Azure using **GitHub Copilot App Modernization** within the [**Copilot CLI**](https://docs.github.com/en/copilot/how-tos/use-copilot-agents/use-copilot-cli), enabling them to modernize applications wherever they code. It’s currently in public preview — give it a try and let us know if any [feedback](https://aka.ms/ghcp-appmod/feedback). | ||
| :::image type="content" source="./media/copilot-cli-entrance.png" lightbox="./media/copilot-cli-entrance.png" alt-text="Screenshot of app mod entrance in Copilot CLI"::: | ||
|
|
||
| >[!NOTE] | ||
| >GitHub Copilot CLI is available with the GitHub Copilot Pro, GitHub Copilot Pro+, GitHub Copilot Business and GitHub Copilot Enterprise plans. | ||
| >If you receive Copilot from an organization, the Copilot CLI policy must be enabled in the organization's settings. | ||
|
|
||
| ## Why Use Copilot CLI with App Modernization | ||
| - Run modernization tasks directly from the terminal — no need to switch to an IDE | ||
| - Supports both interactive (human-in-the-loop) and batch workflows | ||
alexwolfmsft marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
|
|
||
| ## Prerequisites | ||
| - [Install Copilot CLI](https://docs.github.com/en/copilot/how-tos/set-up/install-copilot-cli) | ||
| - A GitHub Copilot subscription, See [Copilot plans](https://github.com/features/copilot/plans?ref_product=copilot) | ||
alexwolfmsft marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
alexwolfmsft marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
| - Node.js version 22 or later | ||
| - npm version 10 or later | ||
|
|
||
| ## Getting Started | ||
| 1. In your terminal, navigate to the .NET project folder containing the code you want to work on. | ||
| 2. Enter `copilot` to start Copilot CLI. | ||
| ``` | ||
| copilot | ||
| ``` | ||
| Copilot will ask you to confirm that you trust the files in this folder. Refer to [Using Copilot CLI](https://docs.github.com/en/copilot/how-tos/use-copilot-agents/use-copilot-cli#trusted-directories) | ||
alexwolfmsft marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
| Choose one of the options: | ||
alexwolfmsft marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
| - Yes, proceed: Copilot can work with the files in this location for this session only. | ||
| - Yes, and remember this folder for future sessions: You trust the files in this folder for this and future sessions. You won't be asked again when you start Copilot CLI from this folder. Only choose this option if you are sure that it will always be safe for Copilot to work with files in this location. | ||
alexwolfmsft marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
| - No, exit (Esc): End your Copilot CLI session. | ||
alexwolfmsft marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
| 3. You can add MCP servers by running `/mcp add` in Copilot CLI according to the configuration below, here is an example of adding .NET migration MCP: | ||
alexwolfmsft marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
| ``` | ||
| /mcp add net-migrate | ||
| ``` | ||
| Or by manually updating the `~/.config/mcp-config.json` file with the following info. Refer to [Add an MCP server](https://docs.github.com/en/copilot/how-tos/use-copilot-agents/use-copilot-cli#add-an-mcp-server) | ||
alexwolfmsft marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
alexwolfmsft marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
| ``` | ||
| { | ||
| "mcpServers": { | ||
| "dotnet-migrate": { | ||
| "type": "local", | ||
| "tools": [ | ||
| "*" | ||
| ], | ||
| "command": "npx", | ||
| "args": [ | ||
| "-y", | ||
| "net-migrate" // TODO: update to actual package name | ||
alexwolfmsft marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
| ] | ||
| } | ||
| } | ||
| } | ||
| ``` | ||
| You can run `/mcp show` to verify the MCP servers are correctly configured. | ||
alexwolfmsft marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
| ``` | ||
| /mcp show | ||
| ``` | ||
| 4. Execute the migration task in Copilot CLI | ||
alexwolfmsft marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
| To migrate your .NET application to Azure, describe your migration scenario in Copilot CLI. | ||
| For details on predefined migration tasks, see [migration tasks](predefined-tasks.md) | ||
alexwolfmsft marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
| For example: | ||
alexwolfmsft marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
| ``` | ||
| Migrate this app from local file IO to Azure Blob Storage | ||
| ``` | ||
|
|
||
| Then the migration task will be executed and showing progress in Copilot CLI | ||
alexwolfmsft marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
alexwolfmsft marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
| :::image type="content" source="./media/migrate-details.png" lightbox="./media/migrate-details.png" alt-text="Screenshot of migrating .NET in Copilot CLI"::: | ||
|
|
||
| The project has been successfully migrated to Azure, with below summary: | ||
alexwolfmsft marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
| :::image type="content" source="./media/migrate-summary.png" lightbox="./media/migrate-summary.png" alt-text="Screenshot of migrating .NET summary in Copilot CLI"::: | ||
|
|
||
| ## Provide Feedback | ||
| If you have any feedback about GitHub Copilot CLI, please let us know your [feedback](https://aka.ms/AM4DFeedback). | ||
|
|
||
| ## Reference | ||
| - [Using GitHub Copilot CLI](https://docs.github.com/en/copilot/how-tos/use-copilot-agents/use-copilot-cli#using-copilot-cli). | ||
alexwolfmsft marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.