-
Notifications
You must be signed in to change notification settings - Fork 389
Add initial copilot instructions #4855
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
base: main
Are you sure you want to change the base?
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.
Pull request overview
This PR adds initial GitHub Copilot instructions for coding agents working on the esp-hal repository. The instructions provide comprehensive onboarding information to help agents understand the project structure, tooling, and workflows.
Changes:
- Added
.github/copilot-instructions.mdwith detailed guidance on repository structure, xtask commands, MSRV requirements, CI workflows, and development practices
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
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.
Pull request overview
Copilot reviewed 1 out of 1 changed files in this pull request and generated 2 comments.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| - For MSRV: `rustup component add rustfmt clippy --toolchain 1.88.0` | ||
| - For nightly checks (if you use them): `rustup component add rustfmt miri --toolchain nightly` | ||
| - Recommended: make sure `rust-src` is available for cross-target builds where CI uses it: | ||
| - `rustup component add rust-src --toolchain 1.88.0` |
Copilot
AI
Jan 28, 2026
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.
The hardcoded MSRV version "1.88.0" in these examples will become outdated when the MSRV changes. Earlier in the document (lines 38-48), instructions correctly emphasize reading the MSRV dynamically from the CI workflow file. Consider either using placeholder syntax like <MSRV_VERSION> to make it clear these are examples that need to be adapted, or add a note that these specific version numbers are examples only and the actual MSRV should be read from ci.yml.
| - Set up the Espressif `esp` toolchain using `espup`. Prefer the `esp` toolchain version documented in CI or project docs when available. Install it like this (replace <version> with the desired esp toolchain version): | ||
| ```/dev/null/commands.md#L3-3 | ||
| espup install -v <version> | ||
| ``` | ||
| - Note: the `esp` toolchain may be required to reproduce Xtensa builds locally. If the CI workflow uses an `esp` toolchain, mirror that version. |
Copilot
AI
Jan 28, 2026
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.
The instructions recommend using espup install -v <version> but don't specify which version to use. The CI workflow (line 77 in ci.yml) uses xtensa-toolchain version 1.92.0.0. Consider being more specific about which version to install, such as: "Install the esp toolchain using espup. The CI uses xtensa-toolchain version 1.92.0.0, so install a compatible version. For example: espup install -v 1.92.0.0" This would provide clearer guidance for developers setting up their local environment.
This was made by Zed's coding agent, based on the prompt from the documentation with manual edits to not comment on formatting issues, read MSRV from CI files and to set up the esp toolchain.