-
Notifications
You must be signed in to change notification settings - Fork 545
Add copilot-setup-steps.yml to preinstall .NET 10 SDK in GitHub Copilot environment #877
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
Co-authored-by: stephentoub <2642209+stephentoub@users.noreply.github.com>
@copilot, please build the solution. |
Build completed successfully with .NET 10 SDK (10.0.100-rc.1.25451.107): ✅ Build: SUCCESS - 0 errors, 0 warnings (1m 22s) All projects compiled successfully across all target frameworks (.NET 10.0, 9.0, 8.0, Framework 4.7.2, and Standard 2.0). |
Co-authored-by: stephentoub <2642209+stephentoub@users.noreply.github.com>
@copilot, can you add a subsequent step to the setup that will run |
Co-authored-by: stephentoub <2642209+stephentoub@users.noreply.github.com>
This PR adds a
.github/copilot-setup-steps.yml
file to automatically preinstall the .NET 10 SDK in the GitHub Copilot Coding Agent environment.Problem
The GitHub Copilot Coding Agent environment currently lacks the .NET 10 SDK required by this repository. When the agent attempts to build or test the project, it fails with:
This prevents the agent from effectively working with the codebase.
Solution
Following the official GitHub Copilot documentation for customizing the agent environment, this PR adds a
copilot-setup-steps.yml
file that:actions/setup-dotnet@v5
to install the .NET SDKglobal.json
file via theglobal-json-file
parameterdotnet --info
to verify the SDK installationImplementation
The implementation follows the recommended approach from actions/setup-dotnet:
By referencing
global.json
instead of hardcoding the version, this configuration will automatically stay in sync when the SDK version is updated in the future. The semantic version tag@v5
is used for simplicity and maintainability. Thedotnet --info
step provides verification that the SDK was installed correctly.Testing
This pull request was created as a result of the following prompt from Copilot chat.
Original prompt
This pull request was created as a result of the following prompt from Copilot chat.
✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.