Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

Copilot
Copy link
Contributor

@Copilot Copilot AI commented Sep 2, 2025

The Copilot agent was inadvertently committing dotnet-install.sh files to the repository when following the setup instructions in .github/copilot-instructions.md. This occurred because the instructions directed the agent to download the .NET installation script to the current working directory, which is the repository root.

Additionally, the instructions have been updated to reflect that the repository now targets both .NET 10.0 (current) and .NET 9.0 (previous) versions, and comprehensive XAML theming guidelines have been added for SamplesApp development.

Changes Made

Fixed dotnet-install.sh Download Location:

  • Modified the wget command to download dotnet-install.sh to /tmp instead of the current directory
  • Changed from: wget https://dot.net/v1/dotnet-install.sh && chmod +x dotnet-install.sh && ./dotnet-install.sh --channel 9.0
  • Changed to: wget https://dot.net/v1/dotnet-install.sh -O /tmp/dotnet-install.sh && chmod +x /tmp/dotnet-install.sh && /tmp/dotnet-install.sh --channel 10.0

Updated Copilot Instructions for .NET 10.0 Support:

  • Changed primary .NET SDK installation from channel 9.0 to 10.0
  • Added both wasm-tools-net9 and wasm-tools-net10 to workload installation commands
  • Updated target framework examples to prioritize net10.0 with net9.0 as previous version
  • Expanded Available Platform Targets table to include both .NET 10.0 (current) and .NET 9.0 (previous) entries for all platforms
  • Updated Windows-specific target framework notes to mention both versions
  • Updated commit message examples to reference .NET 10.0

Added XAML Theming Guidelines:

  • Added comprehensive guidelines for using {ThemeResource} colors in SamplesApp XAML samples
  • Specified when to use theme-aware colors vs. explicit colors for test/demo UI
  • Provided examples of proper theming practices with code snippets
  • Listed common ThemeResource colors for reference
  • Ensures samples work well in both light and dark themes while allowing flexibility for color demonstrations

Testing

Verified that:

  • The updated command correctly downloads the script to /tmp
  • The script executes properly from the temporary location using .NET 10.0
  • No files are left in the repository working directory
  • Instructions properly reflect dual .NET version support
  • XAML theming guidelines are clear and actionable for sample development

This ensures the Copilot agent can install .NET as needed without polluting the repository with temporary installation scripts, properly supports both .NET versions used in the repository, and provides clear guidance for creating professional, theme-aware XAML samples.

Fixes #21393.


✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.

@CLAassistant
Copy link

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.
You have signed the CLA already but the status is still pending? Let us recheck it.

@Copilot Copilot AI changed the title [WIP] Copilot agent commits dotnet-install.sh fix: Prevent Copilot agent from committing dotnet-install.sh files Sep 2, 2025
@Copilot Copilot AI requested a review from MartinZikmund September 2, 2025 16:22
Copilot finished work on behalf of MartinZikmund September 2, 2025 16:22
.gitignore Outdated
@@ -264,3 +264,6 @@ mergedstyles.xaml

!build/ci/publish
/doc/articles/llms/llms-full.txt

# Prevent dotnet-install.sh from being committed
dotnet-install.sh
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@copilot Undo the changes to .gitignore

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done. Removed the dotnet-install.sh entry from .gitignore as requested in commit 0214173.

@MartinZikmund
Copy link
Member

@copilot also update copilot instructions to take into account that we now also target .NET 10 alongside .NET 9

Copy link
Contributor Author

Copilot AI commented Sep 2, 2025

@copilot also update copilot instructions to take into account that we now also target .NET 10 alongside .NET 9

Updated the copilot instructions to support both .NET 10.0 (current) and .NET 9.0 (previous). The changes include:

  • Primary .NET SDK installation now uses channel 10.0
  • Workload installation includes both wasm-tools-net9 and wasm-tools-net10
  • Target framework examples prioritize net10.0 with net9.0 as alternative
  • Platform targets table expanded to include both versions for all platforms

Changes committed in 65344c9.

@Copilot Copilot AI changed the title fix: Prevent Copilot agent from committing dotnet-install.sh files fix: Prevent Copilot agent from committing dotnet-install.sh files and update instructions for .NET 10.0 support Sep 2, 2025
Copilot finished work on behalf of MartinZikmund September 2, 2025 16:35
@unodevops
Copy link
Contributor

🤖 Your Docs stage site is ready! Visit it here: https://unodocsprstaging.z13.web.core.windows.net/pr-21394/docs/index.html

@MartinZikmund MartinZikmund changed the title fix: Prevent Copilot agent from committing dotnet-install.sh files and update instructions for .NET 10.0 support fix: Improve copilot instructions Sep 5, 2025
@MartinZikmund
Copy link
Member

@copilot add instructions that whenever a Samples app XAML sample is added, it should prefer to use {ThemeResource} colors for backgrounds and foregrounds, so that the UI works well in both dark and light theme. This does not apply to "test UI", for example for a sample showing shapes you can still use clear red and blue rectangle, because those colors are well legible in both themes

Copy link
Contributor Author

Copilot AI commented Sep 5, 2025

@copilot add instructions that whenever a Samples app XAML sample is added, it should prefer to use {ThemeResource} colors for backgrounds and foregrounds, so that the UI works well in both dark and...

Added XAML theming guidelines to the copilot instructions. The guidelines specify using {ThemeResource} colors for UI elements to ensure proper light/dark theme support, with exceptions for test UI where explicit colors like red and blue rectangles are acceptable for demonstration purposes. See commit 01e1b2a.

@Copilot Copilot AI changed the title fix: Improve copilot instructions fix: Improve copilot instructions with .NET 10.0 support and XAML theming guidelines Sep 5, 2025
Copilot finished work on behalf of MartinZikmund September 5, 2025 14:34
@unodevops
Copy link
Contributor

🤖 Your Docs stage site is ready! Visit it here: https://unodocsprstaging.z13.web.core.windows.net/pr-21394/docs/index.html

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Copilot agent commits dotnet-install.sh
5 participants