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

Re: using/creating hooks within subversion...

From: Toby Johnson <toby_at_etjohnson.us>
Date: 2004-08-26 02:56:50 CEST

m christensen wrote:

> My question was:
> "IF my windows machine is configured such that I, from a command line
> can type "foo.pl" and have
> windows automagically know it's a perl script and call perl with this
> script as a parameter"
> THAN does it follow that I can
> place a 'pre-commit.pl' in the hooks directory and have it execute
> OR Must I have a pre-commit..BAT that calls my pre-commit.pl' ?

Nope, sadly on Windows these aren't the same thing. There are only a few
"executable" extensions; for the rest, Windows calls the associated
program (in this case perl.exe) with the file as a parameter. You can't
type only "pre-commit" on the command line and have it run a .pl file,
but you can do this with .bat, .exe, etc. files.

However, for an example of how to turn any Perl script into a .bat file,
look at any .bat file in c:\perl\bin (assuming you're using
ActiveState); simply replace everything between the #!perl shebang and
the __END__ marker with your script.

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org
Received on Thu Aug 26 02:57:18 2004

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