Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -492,7 +492,7 @@ Run:
```bash
python3 scripts/test_check_release_consistency.py
python3 scripts/check_release_consistency.py
python3 scripts/build_changelog.py --dry-run
python3 scripts/build-changelog.py --dry-run
```

Expected: all commands PASS and dry-run displays the v3.1.0 fragment without modifying `CHANGELOG.md`.
Expand Down
11 changes: 6 additions & 5 deletions scripts/build-changelog.py
Original file line number Diff line number Diff line change
Expand Up @@ -32,11 +32,12 @@
reverse order puts the most recently landed change nearest the top of
``[Unreleased]`` — matching Keep a Changelog's most-recent-on-top
convention instead of burying it at the bottom of the section.
* The compiler inserts fragments BETWEEN the ``## [Unreleased]`` line and
the first ``###`` sub-heading (or end of section if no sub-headings).
Existing inline entries under ``## [Unreleased]`` are PRESERVED below the
inserted fragment block. This lets historical entries continue to live in
CHANGELOG.md while new entries land via fragments going forward.
* The compiler replaces the auto-generated block delimited by the
``<!-- changelog-fragments ... -->`` markers under ``## [Unreleased]``
(or inserts that block immediately after the header if the markers are
absent). Existing inline entries outside the markers are PRESERVED. This
lets historical entries continue to live in CHANGELOG.md while new entries
land via fragments going forward.

LIMITATIONS
* Does NOT migrate existing inline entries. That's deliberate per the M1
Expand Down
6 changes: 3 additions & 3 deletions scripts/build_skills.py
Original file line number Diff line number Diff line change
Expand Up @@ -116,8 +116,8 @@
PLACEHOLDER_RE = re.compile(r"\{\{\s*([a-z][a-z0-9_]*)\s*\}\}")
# Matches the opening ``---`` frontmatter block of a spec.
FRONTMATTER_RE = re.compile(r"^---\n(.*?)\n---\n", re.DOTALL)
# Matches a ``packages:`` list field inside frontmatter YAML (simple inline or
# block list; we use a lightweight regex rather than a YAML parser to keep the
# Matches a ``packages:`` list field inside frontmatter YAML (inline bracket
# form only; we use a lightweight regex rather than a YAML parser to keep the
# build stdlib-only). Captures the value portion after "packages:".
PACKAGES_FIELD_RE = re.compile(
r"^packages:\s*\[([^\]]*)\]", re.MULTILINE
Expand Down Expand Up @@ -345,7 +345,7 @@ def main() -> int:
)
parser.add_argument(
"--package", default=None,
help="generate only for the named package (skip the _active filter)",
help="generate only for the named package",
)
parser.add_argument(
"--spec", default=None,
Expand Down
Loading