Skip to content
GitLab
Next
    • GitLab: the DevOps platform
    • Explore GitLab
    • Install GitLab
    • How GitLab compares
    • Get started
    • GitLab docs
    • GitLab Learn
  • Pricing
  • Talk to an expert
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
    Projects Groups Topics Snippets
  • Register
  • Sign in
  • GitLab GitLab
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributor statistics
    • Graph
    • Compare revisions
    • Locked files
  • Issues 50,620
    • Issues 50,620
    • List
    • Boards
    • Service Desk
    • Milestones
    • Iterations
    • Requirements
  • Merge requests 1,554
    • Merge requests 1,554
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Artifacts
    • Schedules
    • Test cases
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Packages and registries
    • Packages and registries
    • Package Registry
    • Container Registry
    • Infrastructure Registry
  • Monitor
    • Monitor
    • Metrics
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Code review
    • Insights
    • Issue
    • Repository
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • GitLab.orgGitLab.org
  • GitLabGitLab
  • Issues
  • #2557
Closed
Open
Issue created Jun 04, 2017 by Hong Yongmin@revi

Add default issue and merge request templates in a project's repository

Release Notes

In addition to defining default issue and merge request description templates within a project's settings, you can now set default templates in the .gitlab directory of a project's repository by including a default.md file within the issue or merge request templates folders. If default templates exist in both the project's settings and in the repository, the template in the settings will take precedence.

Thanks for the contribution @davebarr!

https://docs.gitlab.com/ee/user/project/description_templates.html#set-a-default-template-for-merge-requests-and-issues

❗ Update

2022-03-16 - Closing this issue as it has been resolved and implemented.

This was originally introduced via !76326 (merged). We recently received a report that this introduced a fairly severe regression (#350358 (closed)) as well as potentially diminishing some "works by default" compliance controls for certain customers.

The suggested course of action is as follows:

  • Revert !76326 (merged) via !78288 (merged)
  • Fix the regression -- addressed in !78302 (merged)
  • Update the logic of default template selection such that the database default template takes precedence over the default.md template if both exist. If no database template exists and default.md does exist, that will be used as the default template. If a database template exists and no default.md exists, the database template will be used as the default. -- addressed in !78302 (merged)

Description

It seems like Default description template for issues and Default description template for merge requests in (project_url)/settings is not able to be loaded from .gitlab folders and thus there are no history on who modified what.

Proposal

Make Default.md or whatever better name for the default templates on preloaded templates.

Links / references

I'm assuming this is an EE feature based on Help page, but if this is also a CE feature, feel free to copy the issue to there.

Documentation blurb

Why should someone use it; what's the underlying problem.

You have no track of the change of default description templates for (issues|merge requests).

What is the solution.

Make .gitlab/ folders to store default templates in addition to other templates and load the default template from there.

How does someone use this

Make a .gitlab/issue_templates/Default.md or .gitlab/merge_requests_template/Default.md and just use it.

Edited Mar 16, 2022 by Gabe Weaver
Assignee
Assign to
Time tracking