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

RE: Emailing user after lock is stolen

From: Reedick, Andrew <jr9445_at_ATT.COM>
Date: Fri, 20 Jun 2008 14:57:25 -0500

> -----Original Message-----
> From: Giulio Troccoli [mailto:Giulio.Troccoli_at_uk.linedata.com]
> Sent: Friday, June 20, 2008 11:17 AM
> To: users_at_subversion.tigris.org
> Subject: Emailing user after lock is stolen
> I have set up few files with the svn:needs-lock property and
> the user to lock the files before they edit them.
> Sometimes however it is necessary, and correct for our process, to
> steal
> the lock. In this case I would like an email to be sent to the
> lock owner to inform him/her that they will need to relock the
> I have change the pre-lock hook to send an email when the lock owner
> not blank or the user who's trying to lock the file. At first I
> that that would have sent the email only when the --force was used to
> steal the lock. Of course I was wrong and the email is sent even if
> option is not used (and the file is already locked by someone else of
> course).
> Now, is there a way to accomplish what I want: send an email to the
> original owner only when the lock is stolen?

Wouldn't that be the pre-unlock hook? Compare the attempted locker's
name against the name in 'svnlook lock'? Does the pre-unlock hook fire
if the lock-thief didn't use --force? Is so you're back at square one.

Plan b would be for the pre-lock to pass the original locker's name to
the post-lock. Compare the names, send email if they're different.
Sending the of locked file list from pre to post should be enough


The information transmitted is intended only for the person or entity to which it is addressed and may contain confidential, proprietary, and/or privileged material. Any review, retransmission, dissemination or other use of, or taking of any action in reliance upon this information by persons or entities other than the intended recipient is prohibited. If you received this in error, please contact the sender and delete the material from all computers. GA625

To unsubscribe, e-mail: users-unsubscribe_at_subversion.tigris.org
For additional commands, e-mail: users-help_at_subversion.tigris.org
Received on 2008-06-20 21:58:47 CEST

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.