Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Conventional commits with more than one type(area) doesn't appear in changelog #553

Closed
1 task done
ArtemkaKun opened this issue Mar 14, 2024 · 2 comments
Closed
1 task done
Assignees
Labels
bug Something isn't working

Comments

@ArtemkaKun
Copy link

ArtemkaKun commented Mar 14, 2024

Is there an existing issue for this?

No

  • I have searched the existing issues

Description of the bug

I have a commit doc(repo), setup(ci): improve PR naming section in CONTRIBUTING and it doesn't appear in the changelog either as a conventional or unconventional commit. Preprocessing doesn't change anything.

Steps To Reproduce

Config

[changelog]
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") %}\
    \n
    ## {{ group | upper_first }}\
    {% for group, commits in commits | group_by(attribute="scope") %}\
    	\n
        ### {{ group | upper_first }}\n\
        {% for commit in commits | unique(attribute="message") %}\
            \n- {{ commit.message | split(pat="\n") | first | trim }}\
              {% if commit.github.username %} by @{{ commit.github.username }}{% endif %}\
              {% if commit.github.pr_number %} in #{{ commit.github.pr_number }}{% endif %}\
    	{% endfor %}\
    {% endfor %}\
{% endfor %}\
\n
## First-time contributors 🥳\n\
{% for contributor in github.contributors | filter(attribute="is_first_time", value=true) %}\
    \n- @{{ contributor.username }} made their first contribution in #{{ contributor.pr_number }}\
{% endfor %}\
"""

trim = true

[git]
conventional_commits = true
filter_unconventional = false
split_commits = false

commit_parsers = [
    { message = "^feat", group = "✨ Features" },
    { message = "^fix", group = "🪲 Bug Fixes" },
    { message = "^doc", group = "📚 Documentation" },
    { message = "^optimization", group = "🚀 Performance" },
    { message = "^refactor", group = "🧹 Refactor" },
    { message = "^setup", group = "⚙️ Configuration" },
    { message = "^test", group = "✅ Testing" },
    { message = ".*", group = "TEST", default_scope = "other"},
]

commit_preprocessors = [
    { pattern = '^(fix|feat|setup|doc|refactor|test|optimization)\([A-Za-z0-9_-]+\)(, (fix|feat|setup|doc|refactor|test|optimization)\([A-Za-z0-9_-]+?\))+(:\ .*)$', replace = "foo" },
]

protect_breaking_commits = false
filter_commits = false
tag_pattern = "v[0-9].*"
skip_tags = ""
ignore_tags = ""
topo_order = false
sort_commits = "oldest"

Command

git cliff --github-token * --github-repo * --output CHANGELOG.md

Expected behavior

Commit doc(repo), setup(ci): improve PR naming section in CONTRIBUTING transformed into foo and appears together with unconventional commits.

Screenshots / Logs

No response

Software information

Additional context

No response

@ArtemkaKun ArtemkaKun added the bug Something isn't working label Mar 14, 2024
Copy link

welcome bot commented Mar 14, 2024

Thanks for opening your first issue at git-cliff! Be sure to follow the issue template! ⛰️

@ArtemkaKun ArtemkaKun changed the title Convecntional commits with more than one type(area) doesn't appear in changelog Conventional commits with more than one type(area) doesn't appear in changelog Mar 14, 2024
@ArtemkaKun
Copy link
Author

Closing since the issue #554 describes origin of the problem

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants