Skip to content

{Misc.} Add Copilot instructions to prevent manual HISTORY.rst edits - #34202

Merged
Yeming Liu (isra-fel) merged 2 commits into
Azure:devfrom
isra-fel:docs/history-rst-copilot-instructions
Oct 9, 2026
Merged

Yeming Liu (isra-fel) merged 2 commits into
Azure:devfrom
isra-fel:docs/history-rst-copilot-instructions

Conversation

@isra-fel

Copy link
Copy Markdown
Member

Related command
N/A (repository tooling / GitHub Copilot review instructions)

Description
Release history notes in HISTORY.rst are generated automatically from PR titles and descriptions by the release pipeline (scripts/release/generate_history_notes.py), and reviewers routinely ask contributors to revert manual edits to these files. This PR adds a .github/instructions/history-rst.instructions.md file (scoped via applyTo: "**/HISTORY.rst") so GitHub Copilot can detect and flag manual HISTORY.rst changes during PR review and request a revert while preserving functional changes.

The guidance mirrors existing reviewer feedback, e.g.:

  • "please revert the changes to the HISTORY.rst, as the history notes would be generated automatically."
  • "revert this PR's manual change to src/azure-cli/HISTORY.rst, since release history is generated automatically."

It also documents the Hotfix exception described in doc/authoring_command_modules/README.md.

Testing Guide
Documentation/tooling-only change (no code). The new file follows the same frontmatter format as the existing .github/instructions/*.instructions.md files and is auto-discovered by its applyTo/description frontmatter.

History Notes

Release history notes are generated automatically from PR titles and
descriptions. Add a .github/instructions file so GitHub Copilot flags
manual HISTORY.rst changes during PR review and requests reverts.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copilot-Session: 4b6414b3-5257-4e50-bf71-865cf4cc38b6
Copilot AI balanced review requested due to automatic review settings October 9, 2026 05:20

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

🟡 Changes recommended

The glob incorrectly covers changelogs not managed by the referenced generation script.

1 open finding
What changed in this PR

Adds Copilot review guidance to prevent manual edits to auto-generated release histories.

Changes:

  • Adds scoped HISTORY.rst review instructions.
  • Documents title/description generation and the hotfix exception.
File Description
.github/​instructions/​history-rst.instructions.md Defines release-history editing guidance.

🧠 Review effort: Balanced


💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment thread .github/instructions/history-rst.instructions.md Outdated
Update applyTo path for HISTORY.rst instructions.

Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
@isra-fel
Yeming Liu (isra-fel) merged commit cc010d2 into Azure:dev Oct 9, 2026
50 checks passed
@isra-fel
Yeming Liu (isra-fel) deleted the docs/history-rst-copilot-instructions branch October 9, 2026 06:44
@yonzhan Yong Zhang (yonzhan) added this to the Backlog milestone Oct 9, 2026
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.

4 participants