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

automatic server-side setting of svn:keywords using hooks

From: Johannes Egger <johannes.egger_at_tigerlair.net>
Date: Thu, 31 Jan 2008 11:06:33 +0100 (CET)

Dear List,

I've recently been wondering whether there's a way to automatically add specific svn:keywords
properties to non-binary files on the server side. I know about auto-prop support, but it only
works on the client side.

After some digging I found this issue: http://subversion.tigris.org/issues/show_bug.cgi?id=1974
which is somewhat related to what I want to do, but not exactly.

Anyway, since propagating specific configuration settings to clients is not yet supported, I'm
wondering whether one could modify the transaction in a commit hook to set svn:keywords="Id Author
Date" for all *new* (added) non-binary files. One could check whether the file is non-binary using
the 'file' unix command, or specify a number of file suffixes that are known text files (e.g. "pl
plx pm css htm html js cpp c h java").

I saw a big warning at http://svnbook.red-bean.com/en/1.1/ch05s02.html (subversion 1.1) about
modifying a transaction using hook scripts. The 1.1 version of the book specifically mentions
svn:eol-style and svn:mime-type. This is understandable.

Version 1.4 is more explicit and talks about the client-side cache which might become stale. Is
this a problem for *all* transaction modifications? Does it apply to svn-keywords?

Is there any other way to automatically set properties on the server-side that I'm not aware of?

Best regards,

To unsubscribe, e-mail: users-unsubscribe_at_subversion.tigris.org
For additional commands, e-mail: users-help_at_subversion.tigris.org
Received on 2008-01-31 11:09:30 CET

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

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.