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

Re: pre-revprop-change

From: Ryan Schmidt <subversion-2008a_at_ryandesign.com>
Date: Thu, 28 Feb 2008 01:36:52 -0600

On Feb 27, 2008, at 23:46, Nathan Nobbe wrote:

> i am trying to set the svn:eol-style property on a repository of
> mine and starting to loose hair as a consequence of this error
> message:
>
> svn: DAV request failed; it's possible that the repository's pre-
> revprop-change hook either failed or is non-existent
> svn: At least one property change failed; repository is unchanged
>
> ive searched the archives and read the manual on setting the
> property and the hook scripts.
> i should be on the right track, but something still isnt copacetic.
> for property changes, you must have a hook defined, otherwise svn
> will act as if the hook failed every time.
> fair enough, so what ive done is defined the hook by removing
> the .tmpl extension on the template file that ships w/ the repo.
> and the script is executable as well,
> -rwxr-xr-x 1 apache apache 58 Feb 28 00:39 /moxune/repository/hooks/
> pre-revprop-change
>
> great, so im still getting the error message.
> to rule out the latter part of the message, namely does the script
> exist, i have added some trivial logging to the script,
> which is writing out to the target file, indicating the script not
> only exists, but svn is successfully invoking it.
> and for the former part of the message, is the script failing, well
> all its doing is echoing a string to a file and calling exit 0 so i
> dont think its failing.
> here is my hook script
>
> #!/bin/sh
> echo 'called me' >> /home/nathan/imCrazy
> exit 0
>
> and as i said, 'called me' is getting written to /home/nathan/
> imCrazy; twice actually (dont know why)
> i dont know how i could write any more trivial of a hook script.
> afaict, this should be returning successfully to the caller and the
> property should be getting set in the repository.
> here is the command im using to invoke the property change
>
> svn propset eol:style --revprop -r HEAD native https://
> dev.moxune.com/svn/repos/sentinelWorking/branches/sentinel_v1.2/code

First of all, it's called "svn:eol-style" (not "eol:style").

Second, it's a file property, not a revision property. You do not
need a pre-revprop-change hook, because you're not going to be
changing a revision property.

Go to a working copy and set the svn:eol-style property of the file
whose line endings you want to specify. For example:

cd working-copy
svn propset svn:eol-style native foo.txt
svn ci -m "foo.txt: setting svn:eol-style to native"

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe_at_subversion.tigris.org
For additional commands, e-mail: users-help_at_subversion.tigris.org
Received on 2008-02-28 08:37:35 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.