Skip to content
Snippets Groups Projects

Add local_reference (Merge Request ID) to commit template

Merged Zadkiel requested to merge zadkiel/gitlab:zadkiel-master-patch-48442 into master

What does this MR do and why?

This PR adds a %{local_reference} Commit message templates variable that resolves to a simple merge request ID like !123. Currently, %{reference} resolves to the full MR reference like path/to/group/project!123.

I'd like to reference IDs in the commit name like GitHub does by default with squash merges (commit message (#PR-ID)).

Solves #199823

TODO

MR acceptance checklist

This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.

Edited by Zadkiel

Merge request reports

Loading
Loading

Activity

Filter activity
  • Approvals
  • Assignees & reviewers
  • Comments (from bots)
  • Comments (from users)
  • Commits & branches
  • Edits
  • Labels
  • Lock status
  • Mentions
  • Merge request status
  • Tracking
  • Zadkiel resolved all threads

    resolved all threads

  • Zadkiel added 1 commit

    added 1 commit

    • ab04262d - Apply 1 suggestion(s) to 1 file(s)

    Compare with previous version

  • Zadkiel added 1 commit

    added 1 commit

    Compare with previous version

  • Zadkiel mentioned in issue #199823

    mentioned in issue #199823

  • Zadkiel changed the description

    changed the description

  • GitLab has made changes to its merge request feature, allowing users to reference merge requests using a local reference or merge request ID. This new feature has been added to the commit message template, making it easier for developers to reference merge requests in their commit messages. Additionally, GitLab has added other variables to the template to improve the user experience.


    (AI-generated summary for revision 0c601d87)

  • Zadkiel added 1 commit

    added 1 commit

    • 61909e65 - 1 commit from branch gitlab-org:master

    Compare with previous version

  • Zadkiel added 3 commits

    added 3 commits

    Compare with previous version

  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Please register or sign in to reply
    Loading