-
Notifications
You must be signed in to change notification settings - Fork 480
[Housekeeping] Add Co-Pilot Prompts #2575
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
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
PR Overview
This PR introduces a set of natural language prompts and guidelines to enhance GitHub Copilot's automated code review and development assistance for the .NET MAUI Community Toolkit. The changes include:
- A new async best practices cheat sheet.
- Detailed usage instructions for GitHub Copilot with .NET MAUI.
- Prompts covering memory leak patterns and control usage issues.
- An aggregated index of available prompts.
Reviewed Changes
| File | Description |
|---|---|
| .github/prompts/dotnet/async.prompt.md | Adds asynchronous programming best practices and guidelines. |
| .github/copilot-instructions.md | Introduces instructions for setting up and using GitHub Copilot with .NET MAUI. |
| .github/prompts/dotnet/maui/maui-memory-leaks.prompt.md | Provides guidance and examples for avoiding memory leaks in MAUI apps. |
| .github/prompts/dotnet/maui/maui-controls.prompt.md | Implements a XAML snippet and best practices for page life-cycle and control usage. |
| .github/prompts/prompts.prompt.md | Aggregates links to all the prompt instructions. |
Copilot reviewed 5 out of 5 changed files in this pull request and generated 3 comments.
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
| <toolkit:EventToCommandBehavior | ||
| EventName="Appearing" | ||
| Command="{Binding AppearingCommand}" /> | ||
| </ContentPage.Behaviors> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this xaml is not finished. is it expected?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@VladislavAntonyuk You are correct, but the example code in the prompts are there only to guide CoPilot and aren't there for direct user reading. Think of them like the old Visual Studio 'snippets'. This one however, is easy to 'complete' and I will complete it.
@TheCodeTraveler I think you may have ever so slightly missed where this is primarily directed. All of the |
@TheCodeTraveler I have added MORE prompts to my fork, as I [always] get a 403 when I try to push to this branch [actually, I get a 403 when I try to push to ANY branch in the repository]! I have added prompts for xUnit and also for Code Style. I think the xUnit will be of real benefit...but they ALL need review, clarification and adding to. |
|
Amazing! Thanks George! Could you open a PR from your fork so that we get the new things merged too? Once you've opened the new PR, I'll close this one. |
Brandon. Will do very shortly! |
|
Closing in favor of #2576 |
Description of Change
This PR adds natural language instructions for CoPilot to assist with its automated code reviews.
More the the docs:
Linked Issues
PR Checklist
mainat time of PRAdditional Information
The work done on this PR is attributed to @GeorgeLeithead