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

Re: Managing "needs-lock" files on multiple branches

From: Mark Phippard <markphip_at_gmail.com>
Date: Thu, 13 Jun 2013 16:09:35 -0400

On Thu, Jun 13, 2013 at 4:05 PM, Benjamin Fritz <fritzophrenic_at_gmail.com> wrote:
> On Thu, Jun 13, 2013 at 2:47 PM, Mark Phippard <markphip_at_gmail.com> wrote:
>>
>> The hook is running on the server, so it could access the repository
>> via file:// URL to do the lock. This does not require authentication.
>>
>
> I DID NOT KNOW THIS! Is that documented somewhere? This should allow
> my pre-lock hook to work exactly as I wanted! What other svn commands
> that also behave this way?

Which other commands support file:// ? All of them do. file:// is
one of the supported "RA" mechanisms for Subversion - ra_local. See:

http://svnbook.red-bean.com/en/1.7/svn.intro.whatis.html#svn.intro.architecture

>> In SVN 1.8, the svnadmin command can be used as well:
>>
>> $ svnadmin help lock
>> lock: usage: svnadmin lock REPOS_PATH PATH USERNAME COMMENT-FILE [TOKEN]
>>
>
> I don't know what version of SVN is running on our server, but I know
> it is definitely less than 1.8, sadly.

SVN 1.8 has not been released yet. Was just pointing out that this is coming.

> I've made sure the pre-lock hook will succeed under normal
> circumstances (i.e. file is not locked, or --force was passed) if the
> file is NOT on a branch. So a recursive call to lock a file NOT on a
> branch shouldn't be a problem, right?

Not sure I understand the question. You probably just have to test
the scenario and see what output the command gives you.

Note that you are going to need to a means to remove these locks. You
ought to be able to do unlock with hook scripts, just test it well and
make sure you accounted for everything.

--
Thanks
Mark Phippard
http://markphip.blogspot.com/
Received on 2013-06-13 22:10:06 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.