Skip to content

Commit 9bec2ca

Browse files
committed
Update CoPilot instructions
1 parent a128730 commit 9bec2ca

File tree

2 files changed

+31
-4
lines changed

2 files changed

+31
-4
lines changed

.github/copilot-instructions.md

Lines changed: 30 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ These instructions define how GitHub Copilot should assist with this project. Th
2323
- **Documentation**: The project provides documentation in the form of wiki pages available at [Documentation](https://github.com/microsoft/DirectXTK/wiki/).
2424
- **Error Handling**: Use C++ exceptions for error handling and uses RAII smart pointers to ensure resources are properly managed. For some functions that return HRESULT error codes, they are marked `noexcept`, use `std::nothrow` for memory allocation, and should not throw exceptions.
2525
- **Testing**: Unit tests for this project are implemented in this repository [Test Suite](https://github.com/walbourn/directxtktest/) and can be run using CTest per the instructions at [Test Documentation](https://github.com/walbourn/directxtktest/wiki).
26-
- **Security**: This project uses secure coding practices from the Microsoft Secure Coding Guidelines, and is subject to the `SECURITY.md` file in the root of the repository. Functions that read input from image file, geometry files, and audio files are subject to OneFuzz testing to ensure they are secure against malformed files.
26+
- **Security**: This project uses secure coding practices from the Microsoft Secure Coding Guidelines, and is subject to the `SECURITY.md` file in the root of the repository. Functions that read input from image file, geometry files, and audio files are subject to OneFuzz fuzz testing to ensure they are secure against malformed files.
2727
- **Dependencies**: The project uses CMake and VCPKG for managing dependencies, making optional use of DirectXMath, GameInput, and XAudio2Redist. The project can be built without these dependencies, relying on the Windows SDK for core functionality.
2828
- **Continuous Integration**: This project implements GitHub Actions for continuous integration, ensuring that all code changes are tested and validated before merging. This includes building the project for a number of configurations and toolsets, running a subset of unit tests, and static code analysis including GitHub super-linter, CodeQL, and MSVC Code Analysis.
2929
- **Code of Conduct**: The project adheres to the [Microsoft Open Source Code of Conduct](https://opensource.microsoft.com/codeofconduct/). All contributors are expected to follow this code of conduct in all interactions related to the project.
@@ -65,12 +65,13 @@ Tests/ # Tests are designed to be cloned from a separate repository at
6565

6666
## References
6767

68+
- [Source git repository on GitHub](https://github.com/microsoft/DirectXTK.git)
69+
- [DirectXTK documentation git repository on GitHub](https://github.com/microsoft/DirectXTK.wiki.git)
70+
- [DirectXTK test suite git repository on GitHub](https://github.com/walbourn/directxtktest.wiki.git).
6871
- [C++ Core Guidelines](https://isocpp.github.io/CppCoreGuidelines/CppCoreGuidelines)
6972
- [Microsoft Secure Coding Guidelines](https://learn.microsoft.com/en-us/security/develop/secure-coding-guidelines)
7073
- [CMake Documentation](https://cmake.org/documentation/)
71-
- [VCPK Documentation](https://learn.microsoft.com/vcpkg/)
72-
- [DirectX Tool Kit for DirectX 11 Wiki](https://github.com/microsoft/DirectXTK/wiki/)
73-
- [DirectX Tool Kit for Audio Wiki](https://github.com/Microsoft/DirectXTK/wiki/Audio)
74+
- [VCPKG Documentation](https://learn.microsoft.com/vcpkg/)
7475
- [Games for Windows and the DirectX SDK blog - March 2012](https://walbourn.github.io/directxtk/)
7576
- [Games for Windows and the DirectX SDK blog - January 2013](https://walbourn.github.io/directxtk-update/)
7677
- [Games for Windows and the DirectX SDK blog - December 13](https://walbourn.github.io/directx-tool-kit-for-audio/)
@@ -107,3 +108,28 @@ When creating documentation:
107108
- Review each documented item against source code whenever related to the task.
108109
- Remove any speculative content.
109110
- Ensure all documentation is verifiable against the current state of the codebase.
111+
112+
## Code Review Instructions
113+
114+
When reviewing code, focus on the following aspects:
115+
116+
- Adherence to coding standards defined in `.editorconfig` and on the [wiki](https://github.com/microsoft/DirectXTK/wiki/Implementation).
117+
- Make coding recommendations based on the *C++ Core Guidelines*.
118+
- Proper use of RAII and smart pointers.
119+
- Correct error handling practices and C++ Exception safety.
120+
- Clarity and maintainability of the code.
121+
- Adequate comments where necessary.
122+
- Public interfaces are located in `Inc\*.h` should be clearly defined and documented on the GitHub wiki.
123+
- Compliance with the project's architecture and design patterns.
124+
- Ensure that all public functions and classes are covered by unit tests located on [GitHub](https://github.com/walbourn/directxtktest.git) where applicable. Report any gaps in test coverage.
125+
- Check for performance implications, especially in geometry processing algorithms.
126+
- Provide brutally honest feedback on code quality, design, and potential improvements as needed.
127+
128+
## Documentation Review Instructions
129+
130+
When reviewing documentation, do the following:
131+
132+
- Read the code located in [this git repository](https://github.com/microsoft/DirectXTK.git) in the main branch.
133+
- Review the public interface defined in the `Inc` folder.
134+
- Read the documentation on the wiki located in [this git repository](https://github.com/microsoft/DirectXTK.wiki.git).
135+
- Report any specific gaps in the documentation compared to the public interface.

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@
1818
*.VC.db
1919
*.nupkg
2020
.vs
21+
.vscode
2122
Bin
2223
packages
2324
/Src/Shaders/Compiled/*.inc

0 commit comments

Comments
 (0)