Changelog Templates¶
Customize your changelog format.
Overview¶
releasio provides flexible template options for changelog entries:
- Section headers - Group commits by type
- Commit templates - Format individual entries
- Custom sections - Add your own groupings
Commit Templates¶
Basic Template¶
Output:
With Issue Links¶
Output:
With Author¶
Output:
With Commit Hash¶
.releasio.toml
[changelog]
commit_template = "- {description} ([{short_hash}]({commit_url}))"
show_commit_hash = true
Output:
Full Template¶
.releasio.toml
[changelog]
commit_template = "- {description} ([{short_hash}]({commit_url})) by @{author}"
show_authors = true
show_commit_hash = true
Output:
Template Variables¶
| Variable | Description | Example |
|---|---|---|
{description} |
Commit description | Add user dashboard |
{type} |
Commit type | feat |
{scope} |
Commit scope | api |
{hash} |
Full commit hash | abc123def456... |
{short_hash} |
Short hash (7 chars) | abc123d |
{author} |
Author username | username |
{author_email} |
Author email | user@example.com |
{pr_number} |
PR number (if available) | 42 |
{commit_url} |
Full commit URL | https://github.com/... |
{date} |
Commit date | 2024-01-15 |
Section Headers¶
Default Headers¶
.releasio.toml
[changelog.section_headers]
breaking = "Breaking Changes"
feat = "Features"
fix = "Bug Fixes"
docs = "Documentation"
perf = "Performance"
refactor = "Refactoring"
test = "Testing"
build = "Build"
ci = "CI/CD"
chore = "Chores"
With Emojis¶
.releasio.toml
[changelog.section_headers]
breaking = "๐ฅ Breaking Changes"
feat = "โจ Features"
fix = "๐ Bug Fixes"
docs = "๐ Documentation"
perf = "โก Performance"
refactor = "โป๏ธ Refactoring"
test = "๐งช Testing"
build = "๐ฆ Build"
ci = "๐ง CI/CD"
Minimal¶
Section Order¶
Control the order of sections:
.releasio.toml
[changelog]
section_order = [
"breaking",
"feat",
"fix",
"perf",
"docs",
"refactor",
]
Sections appear in this order. Unlisted types are appended at the end.
Header Format¶
Version Header¶
Output:
Without Date¶
Output:
With Link¶
Output:
Scope Handling¶
Include Scope in Entry¶
Output:
Group by Scope¶
Output:
Example Configurations¶
Keep a Changelog Format¶
Following keepachangelog.com style:
.releasio.toml
[changelog]
path = "CHANGELOG.md"
[changelog.section_headers]
feat = "Added"
fix = "Fixed"
breaking = "Changed"
deprecated = "Deprecated"
removed = "Removed"
security = "Security"
[changelog]
version_header_template = "## [{version}] - {date}"
commit_template = "- {description}"
GitHub Style¶
Optimized for GitHub rendering:
.releasio.toml
[changelog]
path = "CHANGELOG.md"
show_authors = true
show_commit_hash = true
commit_template = "- {description} ([{short_hash}]({commit_url})) @{author}"
[changelog.section_headers]
breaking = "โ ๏ธ Breaking Changes"
feat = "๐ Features"
fix = "๐ Bug Fixes"
docs = "๐ Documentation"
perf = "โก Performance"
Minimal Style¶
Simple, no frills:
.releasio.toml
[changelog]
path = "CHANGELOG.md"
commit_template = "- {description}"
[changelog.section_headers]
feat = "New"
fix = "Fixed"
Filtering Commits¶
Exclude Types¶
Include Only¶
Exclude Scopes¶
First-Time Contributors¶
Highlight new contributors:
.releasio.toml
[changelog]
show_first_time_contributors = true
first_contributor_badge = "๐ First contribution!"
Output:
Dependency Updates¶
Include or exclude dependency bumps:
.releasio.toml
[changelog]
include_dependency_updates = true
dependency_section_header = "๐ฆ Dependencies"
Output:
See Also¶
- git-cliff Integration - Advanced templating
- Conventional Commits - Commit format
- Configuration Reference - All options