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

Re: Can client-side hooks run a script not in working copy?

From: Stefan Küng <tortoisesvn_at_gmail.com>
Date: Mon, 05 Aug 2013 19:22:48 +0200

On 05.08.2013 18:15, Ben Fritz wrote:
> http://tortoisesvn.net/docs/release/TortoiseSVN_en/tsvn-dug-propertypage.html#tsvn-dug-propertypage-tsvn-props
> says, "you can configure a script/tool to execute that resides in your
> working copy by specifying the URL in the repository instead, using
> %REPOROOT% as the part of the URL to the repository root".
>
> But what if the script is not in the working copy?

Then it won't work, sorry.

> My repository has multiple projects within, each with its own
> independent trunk/tags/branches. Some people check out the entire
> repository anyway (usually with a sparse checkout) but in general it
> should work regardless of what branch of what project the working copy
> points to.
>
> I am thinking about creating a pre-commit hook that EVERY user on my
> team should use. So it makes sense to me to put it into some
> repository location independent of what project is being worked on.
> But if I do this, it will probably never be in anybody's working copy.
>
> Can I specify a repository path to a file NOT in the working copy, and
> have it run as a hook script? Or do I need to stick it on a common
> network share or something like that?

Sorry, no. That would be a big security issue since then TSVN would
actually execute potentially dangerous and/or malicious code.
At least by only executing script that are in the repository and the
working copy we can assume that you need at least commit access to the
repo to have something execute.

Stefan

-- 
        ___
   oo  // \\      "De Chelonian Mobile"
  (_,\/ \_/ \     TortoiseSVN
    \ \_/_\_/>    The coolest interface to (Sub)version control
    /_/   \_\     http://tortoisesvn.net
------------------------------------------------------
http://tortoisesvn.tigris.org/ds/viewMessage.do?dsForumId=4061&dsMessageId=3062081
To unsubscribe from this discussion, e-mail: [users-unsubscribe_at_tortoisesvn.tigris.org].
Received on 2013-08-05 19:22:56 CEST

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

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