This is probably an environment thing; try dumping the environment to
see what you have to work with (you'll notice that PATH is pretty
limited).
Make sure you explicitly invoke the WSF script by its full path name
*and* you do so via the full path to the "cscript.exe" shell (this is
the command that actually runs the WSH script).
--Tim
On Dec 27, 2006, at 2:03 PM, Andy Levy wrote:
> I'm attempting to write a hook script using Windows Script Host.
> Running WinXP, Subversion 1.4.0, Apache 2.0.55.
>
> I have a pre-commit.wsf in place which, for the moment, just writes
> out the arguments passed into it to a file located in a directory
> which Everyone has full control over, then quits with exit code 1 (I
> can send the script file if it'll help anyone).
>
> When I run the script on the command-line, it executes fine. When run
> as an actual hook script, I get the following output from my client:
>
> Adding: Code\Local\TestCode\hooks
> Error: Commit failed (details follow):
> Error: MERGE request failed on '/Repos/Test/Playgrounds/Andy'
> Error: Failed to start 'C:\Repositories/Test/hooks/pre-commit.wsf'
> hook
>
> Apache runs under the local system account and if I use a .bat file
> for my pre-commit hook, everything is fine. I'd like to avoid having a
> .bat script that just turns around and calls a .wsf script [1],
> however. Based on the discussion here [2], I thought that WSF scripts
> were supported "natively" by now, so I must be missing something in my
> environment's setup.
>
> Unfortunately, it looks like there are very few people writing hooks
> in Windows Script Host as Google searches aren't finding much. Any
> help is greatly appreciated.
>
> [1]: http://cs.ferncrk.com/blogs/stuart/archive/2006/03/19/
> subversion_revision_property_change_script.aspx
>
> [2]: http://svn.haxx.se/dev/archive-2006-03/0748.shtml
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
> For additional commands, e-mail: users-help@subversion.tigris.org
>
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org
Received on Wed Dec 27 23:26:33 2006