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

Re: Subversion locally and TortoiseSVN client on the same machine?

From: Kevin Grover <kevin_at_kevingrover.net>
Date: Tue, 6 May 2008 13:20:12 -0700

On Mon, May 5, 2008 at 2:19 PM, elthombre <getmyemails2_at_yahoo.com> wrote:

> OK, so then in order to do this, I need to install Apache? Am I
> correct in that understanding? I've done that before on another
> machine so no problems here.
>
> Also, once Apache is installed, do I need to configure via the command
> line or are there other options?
>
> You know us Windows people... take away our GUI and we're in
> trouble ;-)
>
>
>
> On May 5, 2:52 pm, "Andy Levy" <andy.l..._at_gmail.com> wrote:
> > On Mon, May 5, 2008 at 2:33 PM, elthombre <getmyemai..._at_yahoo.com>
> wrote:
> > > Hey All,
> >
> > > While not new to TortoiseSVN client, I am new to trying to configure
> > > the server and client on the same machine, i.e. my laptop ;-)
> >
> > > Here is what I've done:
> >
> > > Ran the windows installer for Subversion
> > > Already have TortoiseSVN running
> >
> > > I want to create my own personal Subversion server locally that I can
> > > use with the TortoiseSVN client for my own personal projects, etc.
> >
> > > Anyone else out there doing this?
> >
> > Yep.
> >
> > > If so, how difficult is this to get up and running?
> >
> > No more difficult than setting up on a regular server.
> >
> > > Perhaps there have been similar posts but I couldn't find anything
> > > regarding running all of this locally on a Windows XP machine.
> >
> > Runs fine. I use Apache for my local service.
> >
>

He said that _he_ uses Apache for his local server, not that you must. You
can do whatever you want. I have SVN running on Linux and Windows machines
using svn:// (svnserver), http:// (apache), and file:// (svn library -- e.g.
virtually all clients).

Easiest is file://. It will just work, but it's not the best if anyone else
needs access, or you need to access repositories from multiple computers.
Second easiest is svn://. You just need to create a directory to hold
repositories and then run svnserve. It's all in the book.
Third is http://. It a little more difficult to set up, but offers the most
options (authentication, control, encryption, etc).

I use a batch script, mksvnservice.bat, to create a service in Windows.
It's basically the command from the book wrapped in a batch file because I
could never remember the syntax (and kept having to look it up).

------------------ start: mksvnservice.bat
@echo off
rem $Id: mksvnservice.bat 127 2008-04-07 14:39:20Z kogrover $
rem $URL: file:///c:/repos/svn/svnutil/trunk/dos/mksvnservice.bat $
rem
rem Create SVN Service for Windows XP (NT, ...)
rem
rem 2007-03-15 Kevin Grover <kevin_at_kevingrover.net>
rem TODO:
rem - Use env var SVNSERVE to specify EXE?
rem - Make Robust (if service exists) ...

setlocal

rem Config...
set SVNDIR=c:\Program Files\Subversion\bin

rem The svnserve EXE
set SVNSRV=%SVNDIR%\svnserve.exe

if "%1"=="help" goto :usage
if "%1"=="install" goto :install
if "%1"=="delete" goto :delservice
if "%1"=="show" goto :showservice
goto :usage

:install
if not exist "%SVNSRV%" goto :noexe
if "%2"=="" goto :norepogiven
set REPOS=%2
if not exist "%REPOS%" goto :norepofound

echo Creating svnserve service on dir %REPOS%
sc create svnserve binpath= "\"%SVNSRV%\" --service --root \"%REPOS%\""
displayname= "Subversion Server" depend= tcpip start= auto
echo Starting svnserve service
sc start svnserve
goto :eof

:delservice
echo Deleting svnserve service
sc delete svnserve
goto :eof

:showservice
sc query svnserve
goto :eof

:usage
echo Usage: mksvnservice [ help ^| install ^<directory^> ^| delete ^| show ]

echo help Shows this help
echo install Install the svnserve service (specifying directory)
echo delete Deletes the svnserve service
echo show Show details about the svnserve service
echo.
echo Commands you can use with the 'svn' svnserve service:
echo net stop svnserve # Stop the service
echo net start svnserve # Start the service
echo sc delete svnserve # Permanently delete the service
goto :eof

:norepofound
echo ERROR: No repository directory found (tried %REPOS%)
goto :eof

:norepogiven
echo ERROR: No repository specified (see usage)
goto :eof

:noexe
echo ERROR: svnserve.exe not found: %SVNSRV%
echo The script needs to be edited
goto :eof
-------------------- end: mksvnservice.bat
Received on 2008-05-06 22:20:24 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.