[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: Automatic ChangeLog generation

From: Bryan Donlan <bdonlan_at_gmail.com>
Date: 2004-07-24 23:50:41 CEST

On Sat, 24 Jul 2004 10:55:36 +0200, Christian Gudrian
<christian.gudrian@gmx.de> wrote:
> Hello!
>
> I wonder how to make subversion automagically create a ChangeLog file
> after each commit?
>
> I have found a tool called svn2log in the source distribution of nemerle
> (http://www.nemerle.org/) which creates a ChangeLog from within a
> working copy of the repository. However, there are to issues which
> prevent me from using this script from within a post-commit hook:
>
> 1. The directory, the post-commit script runs in, is undefined.

You can cd to some directory of course.

> 2. Before svn log yields the correct log messages, a svn update
> is required -- which cannot be called during a post-commit
> script. And even if it could: see 1.

post-commit can't touch the wc from which the commit was started, but
you could have another wc which it runs svn up in. However, then you'd
need a way of stopping infinite recursion, and preventing the
ChangeLog update commits from being in the ChangeLog, and use a lock
to prevent races when two post-commits are running simultaneously.
Perhaps you should use svn log, and generate the ChangeLog when you're
packaging the software for distribution? Or output the ChangeLog to
somewhere outside the repo.

Also, though I haven't looked at svn2log, it'd probably be possible to
modify it to work with URLs.

-- 
bd
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org
Received on Sat Jul 24 23:51:06 2004

This is an archived mail posted to the Subversion Users mailing list.