Ctrl K
ComunidadGuías…

cliff.toml

Rama master · réplica de lectura del repositorio original.

Archivo original ↗Preguntar a KiBot
[changelog]
header = """
# Changelog

All notable changes to this project will be documented in this file.

The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).

"""
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 %}
        - {{ commit.message | upper_first | trim }}\
          {% if commit.scope %} ({{ commit.scope }}){% endif %}\
    {% endfor %}
{% endfor %}\n
"""
footer = """
{% for release in releases -%}
    {% if release.version -%}
        {% if release.previous.version -%}
            [{{ release.version | trim_start_matches(pat="v") }}]: https://gitlab.com/hook0/hook0/-/compare/{{ release.previous.version }}...{{ release.version }}
        {% else -%}
            [{{ release.version | trim_start_matches(pat="v") }}]: https://gitlab.com/hook0/hook0/-/releases/{{ release.version }}
        {% endif -%}
    {% else -%}
        {% if release.previous.version -%}
            [Unreleased]: https://gitlab.com/hook0/hook0/-/compare/{{ release.previous.version }}...HEAD
        {% endif -%}
    {% endif -%}
{% endfor %}
"""
trim = true

[git]
conventional_commits = true
filter_unconventional = false
split_commits = false
commit_parsers = [
    # The two ways a Conventional Commit says it broke something, and only those two. They are the
    # ones `ci/release-packages` reads to decide how big a release has to be, so a commit grouped
    # here and a commit that forces a major have to be the same commit.
    #
    # `!` immediately before the colon. Written out rather than as `^.*!`, which matched an
    # exclamation mark anywhere and filed `feat(api): let a caller say no!` under Breaking Changes.
    { message = "^[a-zA-Z]+(\\(.+\\))?!:", group = "Breaking Changes" },
    # The footer, in both spellings the specification gives it, read through `footer` rather than
    # `body`. With `conventional_commits = true` a footer is not part of the body, so the body form
    # matched nothing, and a commit breaking the wire through its footer was published under
    # Changed while the release it forced was a major.
    { footer = "^BREAKING[ -]CHANGE", group = "Breaking Changes" },
    # A `Security:` trailer, and nothing else, is what files a commit here. A commit declares it
    # the way it declares a break — a footer written for a reader that is not human — because the
    # prose of a body is not a signal: it is written to explain a change to someone, not to
    # classify it, and reading it did both wrong at once. `.*security` is case-sensitive, so
    # `Security impact: …` in a body missed, and it is unanchored, so it caught
    # `feat(api): answer every request with a set of security headers` — a commit whose own body
    # says it is not a security fix — and filed it here instead of under Added. The group's only
    # entry was a feature that did not belong in it, while the vulnerability fix of the same
    # release sat under Fixed. The casing is forgiven on the trailer, where forgiving it costs
    # nothing, since a footer token is one either way.
    #
    # git-cliff stops at the first parser whose regex matches, and both neighbours of this line
    # are load-bearing. Below `^fix` the group empties, every commit carrying the trailer going to
    # Fixed. Above the two parsers overhead the Breaking Changes group empties instead, a breaking
    # commit that also carries the trailer being filed here — and `ci/release-packages` would
    # still force a major for it, which is the disagreement `tests/breaking_changes.rs` exists to
    # refuse.
    { footer = "(?i)^security:", group = "Security" },
    { message = "^feat", group = "Added" },
    { message = "^fix", group = "Fixed" },
    { message = "^doc", group = "Documentation" },
    { message = "^perf", group = "Performance" },
    { message = "^refactor", group = "Changed" },
    { message = "^style", group = "Changed" },
    { message = "^test", group = "Testing" },
    { message = "^ci", group = "CI/CD" },
    { message = "^build", group = "Build" },
    { message = "^chore\\(release\\)", skip = true },
    { message = "^release", skip = true },
    { message = "^chore", group = "Other" },
    { message = "^ci", group = "CI" },
]
filter_commits = false
tag_pattern = "^[a-z-]+/v[0-9]+\\.[0-9]+\\.[0-9]+(-[a-zA-Z0-9.]+)?$"
skip_tags = ""
ignore_tags = ""
topo_order = false
sort_commits = "oldest"