Feature #1036

Commit validation checking on comments

Added by Clay McCoy over 14 years ago. Updated over 10 years ago.

Status:NewStart date:2008-04-10
Priority:NormalDue date:2008-04-17
Assignee:-% Done:


Target version:-


My company is going to use Redmine for a new project. We need to enforce that comments on commits reference at least one valid issue. By valid I mean that it is an existing issue number assigned to the committer in a state that makes sense. This doesn't seem to exist.

It seems like it would be pretty easy to add a method to a controller (not familiar enough to know which one yet) that can be passed a user and a comment (and maybe a project too since a repo could be tracked by multiple projects). This method would parse the comment and query the issues in order to let you know if the comment on the commit was valid. Maybe it would return an array of the errors, and an empty array means everything is fine.

This controller method would be available for a commit hook on the repo (svn or git for example) to call with the parameters, and block the commit if there are problems.

Assuming matching user names in the repo and Redmine makes it easier. A second step might be to have a configuration file to map these, or maybe even a gui on the project repository tab. The convention of matching names seems fine for a first draft of this.

If nothing like this exists, I have time to put it in place. Any thoughts are appreciated. Thanks


#1 Updated by Toshi MARUYAMA almost 12 years ago

  • Priority changed from High to Normal
  • Estimated time deleted (32.00)

Also available in: Atom PDF