Project

General

Profile

How to make Git commit history show up at Redmine issue tracker

Added by Brian Hsu about 13 years ago

Hello,

I followed this instruction (http://wiki.dreamhost.com/Redmine) and setup an Redmine site on my DreamHost account with Git repository.

It works fine so far, I could manage my project using Redmine, and commit my code to the Git repository using SSH, and I could browse my source code and commit history using Redmine user interface.

But there is my problem: It does not hook Git commit history with issue tracker like the official Redmine site.

For example, there is a commit log listed on http://www.redmine.org/issues/7000.

But in my case, I created a ticket which is numbered by Redmine as #5, and I created a commit log like the following:

commit 580fdb33877d7b4167863f5138973b7a83b352aa
Author: Brian Hsu <XXXX.XXXX@gmail.com>
Date:   Fri Mar 11 11:43:43 2011 +0800

    Add README file. (#5)

commit 9cf0d98a319ffca501dc541c76a6cff9a32d6146
Author: Brian Hsu <XXXX.XXXX@gmail.com>
Date:   Fri Mar 11 11:40:00 2011 +0800

    Inital commit.

I could see these commit in the source code browser in version control tab and click "#5" to go to the issue #5. But in that ticket, it does not show the commit log of 580fdb33877d7b4167863f5138973b7a83b352aa in that ticket.

So how could I hook Git and Redmine issue tracker?

BTW, I followed the master/develop two branch workflow mentioned by "A successful Git branching model" (http://nvie.com/posts/a-successful-git-branching-model/), so I would also like Redmine to hook the commit in develop branch instead of master.

Thanks.


Replies (4)

RE: How to make Git commit history show up at Redmine issue tracker - Added by Brian Hsu about 13 years ago

Sorry, my fault.

There are keywords to associate the commit history with issue tracker tickets listed on the page settings/edit?tab=repositories

Change my commit log with "refs #5" and it works.

RE: How to make Git commit history show up at Redmine issue tracker - Added by Felix Schäfer about 13 years ago

You can set the keywords to * to have it reference any #id construct.

RE: How to make Git commit history show up at Redmine issue tracker - Added by Alexander Menk almost 11 years ago

Great - that helped me as well.

One important note: After changing the keywords, the repository has to be imported again - otherwise the change is without effect.

RE: How to make Git commit history show up at Redmine issue tracker - Added by Mischa The Evil almost 11 years ago

Alexander Menk wrote:

One important note: After changing the keywords, the repository has to be imported again - otherwise the change is without effect.

FWIW: the repo does not have to be (re-)imported after a change of the keyword settings. The new settings will be used immediately after the change, for every new commit(-message) that is parsed by Redmine.

    (1-4/4)