Skip to content

Commit 1f490e2

Browse files
committed
AGENTS(docs[CHANGES/MIGRATION]): Add changelog maintenance guidelines
why: Document best practices for maintaining CHANGES and MIGRATION files. what: - Add section on file structure and purpose - Document where to put PR references (in files, not commit messages) - Explain rationale: avoid linkback notification noise in PRs - Include examples for section headers and bullet items
1 parent b9fdc2f commit 1f490e2

File tree

1 file changed

+38
-0
lines changed

1 file changed

+38
-0
lines changed

AGENTS.md

Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -330,6 +330,44 @@ EOF
330330
)"
331331
```
332332

333+
### CHANGES and MIGRATION Files
334+
335+
Maintain `CHANGES` (changelog) and `MIGRATION` (upgrade guide) for all user-facing changes.
336+
337+
**File structure:**
338+
- `CHANGES`: Organized by version with sections like `### Breaking changes`, `### New features`, `### Bug fixes`, `### Development`
339+
- `MIGRATION`: Detailed migration instructions with before/after examples
340+
341+
**PR references - where to put them:**
342+
- **DO**: Put PR number in section headers or at end of bullet items in the files
343+
- **DON'T**: Put PR number in commit message titles (causes linkback notification noise in the PR)
344+
345+
**For larger changes with dedicated sections:**
346+
```markdown
347+
#### API Naming Consistency (#507)
348+
349+
Renamed parameters and methods...
350+
```
351+
352+
**For smaller changes in a list:**
353+
```markdown
354+
### Bug fixes
355+
356+
- Fix argument expansion in `rev_list` (#455)
357+
- Remove unused command: `Svn.mergelist` (#450)
358+
```
359+
360+
**Commit messages should NOT include PR numbers:**
361+
```bash
362+
# GOOD - no PR in commit message
363+
CHANGES(docs): Document breaking API changes for 0.39.x
364+
365+
# BAD - PR in commit message creates noise
366+
CHANGES(docs): Document breaking API changes for 0.39.x (#507)
367+
```
368+
369+
The PR reference in the file content creates a clean linkback when the PR merges, while keeping commit messages focused and avoiding duplicate notifications.
370+
333371
## Debugging Tips
334372
335373
When stuck in debugging loops:

0 commit comments

Comments
 (0)