1
1
mirror of https://github.com/orhun/git-cliff.git synced 2025-01-05 22:47:45 +03:00

docs(config): add minimal example

This commit is contained in:
Orhun Parmaksız 2022-01-29 18:53:26 +03:00
parent 2be04f8b22
commit 848d8a587e
No known key found for this signature in database
GPG Key ID: B928720AEC532117
2 changed files with 78 additions and 0 deletions

View File

@ -746,6 +746,66 @@ All notable changes to this project will be documented in this file.
</details>
#### [Minimal](./examples/minimal.toml)
<details>
<summary>Raw Output</summary>
```
## [unreleased]
### Feat
- Support multiple file formats
- Use cache while fetching pages
## [1.0.1] - 2021-07-18
### Chore
- Add release script
### Refactor
- Expose string functions
## [1.0.0] - 2021-07-18
### Docs
- Add README.md
- [**breaking**] Add tested usage example
### Feat
- Add ability to parse arrays
### Fix
- Rename help argument due to conflict
```
</details>
<details>
<summary>Rendered Output</summary>
## [unreleased]
### Feat
- Support multiple file formats
- Use cache while fetching pages
## [1.0.1] - 2021-07-18
### Chore
- Add release script
### Refactor
- Expose string functions
## [1.0.0] - 2021-07-18
### Docs
- Add README.md
- [**breaking**] Add tested usage example
### Feat
- Add ability to parse arrays
### Fix
- Rename help argument due to conflict
</details>
#### [Detailed](./examples/detailed.toml)
<details>

18
examples/minimal.toml Normal file
View File

@ -0,0 +1,18 @@
# configuration file for git-cliff (0.1.0)
[changelog]
# template for the changelog body
# https://tera.netlify.app/docs/#introduction
body = """
{% if version %}\
## [{{ version | trim_start_matches(pat="v") }}] - {{ timestamp | date(format="%Y-%m-%d") }}\
{% else %}\
## [unreleased]\
{% endif %}\
{% for group, commits in commits | group_by(attribute="group") %}
### {{ group | upper_first }}
{% for commit in commits %}\
- {% if commit.breaking %}[**breaking**] {% endif %}{{ commit.message | upper_first }}
{% endfor %}\
{% endfor %}\n
"""