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

Re: pre-commit property update issue

From: Karl Fogel <kfogel_at_red-bean.com>
Date: 2007-10-11 03:23:04 CEST

Dmitry Konyshev <dmitry.konyshev@gmail.com> writes:
> For some reason, I need to update a property of each file in a repos
> on every commit. I've create a pre-commit script in python that does
> all the work. Unfortunately, in some circumstances properties of some
> files don't get updated. Specifically, this happens if a top-most
> directory in the repos is copied.

Changing data on commit from a hook is highly discouraged, because it
means that what's in the repository will be different from what the
client thinks it committed...

> Although I realize that making modifications in current transaction in
> the pre-commit script might be something improper, this works quite
> well in most cases. So, the fact that it fails in only a few
> circumstances looks like a bug to me.

...as you seem to have guessed already :-).

I'm afraid I don't have an answer for your question, and could only
recommend the usual debugging techniques. One problem might be that
when you copy a directory in Subversion, it doesn't actually make
copies of the things below that directory -- they haven't changed, so
they're just included by reference. Read about the "bubble-up" method
for more on this.

   http://subversion.tigris.org/design.html#server.fs.struct.bubble-up
   http://subversion.tigris.org/hacking.html#docs
   http://www.red-bean.com/kfogel/beautiful-code/bc-chapter-02.html

-Karl

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org
Received on Thu Oct 11 03:24:13 2007

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.