---
# Settings for generating changelogs using the GitLab API. See
# https://docs.gitlab.com/ee/api/repositories.html#generate-changelog-data for
# more information.
categories:
  added: Added
  fixed: Fixed
  changed: Changed
  deprecated: Deprecated
  removed: Removed
  security: Security
  performance: Performance
  other: Other

---
# Settings for generating changelogs using the GitLab API. See
# https://docs.gitlab.com/ee/api/repositories.html#generate-changelog-data for
# more information.
categories:
  added: Added
  fixed: Fixed
  changed: Changed
  deprecated: Deprecated
  removed: Removed
  security: Security
  performance: Performance
  other: Other
template: |
  {% if categories %}
  {% each categories %}
  ### {{ title }} ({% if single_change %}1 change{% else %}{{ count }} changes{% end %})

  {% each entries %}
  - [{{ title }}]({{ commit.reference }})\
  {% if author.contributor %} by {{ author.reference }}{% end %}\
  {% if commit.trailers.MR %}\
   ([merge request]({{ commit.trailers.MR }}))\
  {% else %}\
  {% if merge_request %}\
   ([merge request]({{ merge_request.reference }}))\
  {% end %}\
  {% end %}

  {% end %}

  {% end %}
  {% else %}
  No changes.
  {% end %}

Allow custom MR links for changelog entries
Allow custom MR links for changelog entries

This adds support for specifying a custom merge request link for
changelogs, using the trailer "MR". While the value can technically be
both a link and a Markdown reference, I strongly suggest we use regular
links. Regular links are easier to work with from the terminal, and will
work across mirrors (unlike short references such as !123).

See https://gitlab.com/gitlab-com/gl-infra/delivery/-/issues/1551 for
more information.
