Skip to content

fix: merge duplicate version headings in root changelog format#75

Merged
Slokh merged 1 commit intomasterfrom
fix/root-changelog-merge-headings
Mar 18, 2026
Merged

fix: merge duplicate version headings in root changelog format#75
Slokh merged 1 commit intomasterfrom
fix/root-changelog-merge-headings

Conversation

@Slokh
Copy link
Contributor

@Slokh Slokh commented Mar 18, 2026

When using format = "root" with [[fixed]] groups, multiple packages sharing the same version previously produced duplicate ## version headings in CHANGELOG.md. For example:

## 0.1.5 (2025-01-15)
### Patch Changes
- change A

## 0.1.5 (2025-01-15)
### Patch Changes
- change B

Now entries are grouped by version and deduplicated into a single heading:

## 0.1.5 (2025-01-15)
### Patch Changes
- change A
- change B

Backward-compatible: packages at different versions still get separate headings via the existing codepath (group.len() == 1).

Includes a new golden test (root-fixed-group) covering the merged behavior.

@github-actions
Copy link
Contributor

github-actions bot commented Mar 18, 2026

⚠️ Changelog not found.

A changelog entry is required before merging. We've generated a suggested changelog based on your changes:

Preview
---
changelogs: minor
---

Added support for merging duplicate version headings in root changelog format when multiple packages in a fixed group share the same version, deduplicating changelog entries across packages into a single combined heading.

Add changelog to commit this to your branch.

When using format = "root" with [[fixed]] groups, multiple packages
sharing the same version previously produced duplicate ## version
headings. Now entries are grouped by version and deduplicated into a
single heading.

Backward-compatible: packages at different versions still get separate
headings via the existing codepath.

Co-authored-by: Amp <amp@ampcode.com>
Amp-Thread-ID: https://ampcode.com/threads/T-019d023f-0695-753a-832d-a14fa0ca8540
@Slokh Slokh force-pushed the fix/root-changelog-merge-headings branch from 9a6bffb to 11bc5bf Compare March 18, 2026 18:59
@Slokh Slokh merged commit 9de7498 into master Mar 18, 2026
3 checks passed
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.

1 participant