Only allow editing of commit messages if a project-level setting is enabled
In epic &4983 (closed) we discuss adding the ability to edit commit messages through the GitLab UI.
In comment &4983 (comment 453056324) @mayra-cabrera suggested adding a project-level setting for this, allowing projects to disable this feature if desired. I think this is a good idea, as not all projects may wish to give developers the option to edit commits straight from the UI.
The setting in question would be a project setting, is a boolean, and is enabled by default. It should probably be located under General -> Visibility, project features, permissions, similar to the default award emoji setting.
This setting doesn't need to be behind a feature flag.