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

RE: monad hook scripts

From: Arild Fines <arild.fines_at_broadpark.no>
Date: 2006-06-16 16:03:24 CEST

> -----Original Message-----
> From: Molle Bestefich [mailto:molle.bestefich@gmail.com]
> Sent: Wednesday, June 14, 2006 2:22 PM
> To: dev@subversion.tigris.org
> Subject: monad hook scripts
> I see that Subversion 1.4.0 will support .wsf files.
> Has anyone thought about supporting Monad (now dubbed Microsoft Power
> Shell) script files for hook scripts?
> I think they were once named .msh, currently it's .ps1 and .psc1
> (script file vs. console file - difference?).
> The version number of the shell required to run the file is encoded in
> the filename, thus the 1. I much prefer something like a
> #!C:\windows\msh1.exe in the top of files, but I guess encoding it in
> the filename really forces people to think about it. Perhaps
> Subversion could support ".ps?" for hook scripts.

Given that the Powershell installer does not associate .ps1 with
powershell.exe by default (for security reasons), it seems to me that this
would require SVN to deduce the path to powershell.exe in order to execute
.ps1 files as hook scripts. I have a feeling such a change would be
considered too windows-specific.

You can of course run Powershell scripts as hook scripts today the same way
you would run any other unsupported script type, by creating a batch file
that invokes Powershell with the correct parameters:

set PSEXE = "C:\Program Files\Windows Powershell\1.0\powershell.exe"
%PSEXE% %1 %2

Also, may I interest you in my Powershell tab completion for svn.exe?

To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Fri Jun 16 16:05:56 2006

This is an archived mail posted to the Subversion Dev mailing list.