bloodhound-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ryan Ollos <>
Subject Re: Adding a git repository
Date Fri, 31 May 2013 17:52:54 GMT
On Fri, May 31, 2013 at 8:12 AM, Tim Tisdall <> wrote:

> I'm new to both Bloodhound and Trac so am having a little bit of
> difficulty fully understanding how things work.  I've had to try to piece
> things together from a combination of the documentation but I'm a little
> confused.
> I've added "tracopt.versioncontrol.git.* = enabled" to [components]to be
> able to add a git repository.  I then added a repo through the menus Apps >
> Admin > Repositories.  I'm given a message that I should run 'trac-admin
> $ENV repository resync "access_point"'  (which I did), but this seems to
> be done automatically whether I run that command or not.

I get the same result as you. Running the sync command is necessary for
SVN, so I'll have to dig into whether or not that message is just an
misleading artifact of the SVN support that isn't needed for Git.

> I'm also told 'You should also set up a post-commit hook on the repository
> to call trac-admin $ENV changeset added "access_point" $REV for each
> committed changeset.'.  Here's where I'm having the problem...
> My understanding is that Trac used to ping the repo on each page load to
> see if a change occurred but that was changed to use a hook to reduce all
> the unnecessary calls. (makes sense)  However, I tried committing a change
> to the repo and it seems to have been reflected in the web interface
> automatically.  So, is the default in Bloodhound to automatically ping the
> repo on each page load because I haven't incorporated the hook yet?

Yes, I believe so. It appears that you need to set
`repository_sync_per_request = ` (i.e. set the parameter to an empty list)
to disable the "pinging".

> As for adding the hook...  I have no idea what the $REV part of the hook
> should be.  Is that actually an environment variable set by git?  Also, the
> Bloodhound message said to add a hook to post-commit, but the TracGit
> documentation mentions adding a post-receive hook.  I'm not really sure how
> they differ with respect to Trac/Bloodhound's functionality.

The SVN post-commit hook gets passed $REV, but I'm not sure about Git.
There doesn't appear to be any documentation on how to do this. I'll do
some investigation and get back to you in a few hours.

View raw message