MCPcopy
hub / github.com/ManimCommunity/manim / format_changelog

Function format_changelog

scripts/release.py:266–286  ·  view source on GitHub ↗

Create changelog file content with MyST frontmatter.

(
    version: str,
    body: str,
    date: str | None = None,
    title: str | None = None,
)

Source from the content-addressed store, hash-verified

264
265
266def format_changelog(
267 version: str,
268 body: str,
269 date: str | None = None,
270 title: str | None = None,
271) -> str:
272 """Create changelog file content with MyST frontmatter."""
273 title = title or f"v{version}"
274 body = convert_to_myst(body)
275 date_section = f"Date\n: {date}\n" if date else ""
276
277 return f"""---
278short-title: {title}
279description: Changelog for {title}
280---
281
282# {title}
283
284{date_section}
285{body}
286"""
287
288
289# =============================================================================

Callers 2

changelogFunction · 0.85
_fetch_single_releaseFunction · 0.85

Calls 1

convert_to_mystFunction · 0.85

Tested by

no test coverage detected