Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
This quickstart shows you how to create and apply your own tasks when you use GitHub Copilot app modernization.
In code development, enterprises often have different processes and controls to adhere to their organizational policies and business needs. This area is where My Tasks (Custom) come in. Your own task is generated by analyzing code commits from already-migrated code. The task then guides Copilot to remediate code, following the pattern established by the already-migrated code.
The following video demonstrates using GitHub Copilot app modernization to create and apply your own custom task to migrate a Java project to Azure:
Prerequisites
- A GitHub account with GitHub Copilot enabled. A Pro, Pro+, Business, or Enterprise plan is required.
- The latest version of Visual Studio Code. Must be version 1.101 or later.
- GitHub Copilot in Visual Studio Code. For setup instructions, see Set up GitHub Copilot in VS Code. Be sure to sign in to your GitHub account within VS Code.
- GitHub Copilot app modernization. Restart VS Code after installation.
- Java 21 or later.
- Maven or Gradle to build Java projects.
Create your own task
Use the following steps to create your own task:
Clone the Java migration copilot samples repository.
In Visual Studio Code, open the rabbitmq-sender project folder in the samples' repository. Then, check out the project to the source branch.
In the Activity sidebar, open the GitHub Copilot app modernization extension pane, hover the mouse over the TASKS section, and then select Create a Custom Task.
In the pop-up dialog box, select Create new task.
Type migrate rabbitmq to service bus to search for the commit that migrates RabbitMQ. Select the corresponding commit and then select OK.
Select any uncommitted changes from Working tree if they exist, or you can just skip the choice and select OK here.
If you want to import the commits from a file, choose Select Files in the next pop-up dialog box. This option enables you to select files that contain the commit history you want to use for the custom task and the file you selected is processed locally. Select Skip file selection to continue.
A default task name is generated. Rename it custom task migrate rabbitmq and press Enter to confirm.
A default task description is generated. Press Enter to confirm.
Now, your own task for migrating
rabbitmq
is generated and shows in the TASKS - My Tasks section of the GitHub Copilot app modernization pane.
Apply your own task
Use the following steps to apply your own task:
Find your own task in the TASKS - My Tasks section of GitHub Copilot app modernization pane. Run this task by selecting Run Task.
The Copilot chat window with Agent Mode opens automatically and proceeds to run various tools in the Copilot Chat window. It creates plan.md and progress.md for you to review and change. Manually input continue to confirm and proceed with the plan.
During the code changes, repeatedly select Allow to let the agent run Git commands - for example, to check the version control system status or checkout a new branch for migration.
Repeatedly input Continue to confirm the use of tools and wait for the code changes to finish.
After code changes finish, repeatedly input Continue to proceed with the validation and fix iteration loop.
After all validation finishes, review the code changes and confirm them by selecting Keep.