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

Re: Trying to use EditPadPro for my SVN_EDITOR

From: Josh Blair <josh.blair_at_gmail.com>
Date: 2007-06-21 15:44:06 CEST

Ryan, Ulrich,

You guys were right again. I contacted the developer of EditPad Pro for
assistance. He is always quick to reply and very helpful. The editor does
act like a wrapper and can be configured to stay running in the background.
I use this configuration because it is multi-tabbed and I can have multiple
files open at once.

Here is the reply from the developer:

EditPad Pro does not use a wrapper, but it does behave like one if there's
> already an instance of EditPad Pro running. Then the new instance will
> simply tell the old instance to close the file, and quit. You can force
> the new instance to start by specifying the /newinstance parameter on the
> command line. If SVN happens to start the first EditPad Pro instance,
> you'll need to use File|Exit to shut it down, as the X button will only
> hide it. If you want the X button to close EditPad completely, you can
> disable the tray icon in Options, Preferences, System.
> Kind regards,
> Jan Goyvaerts

So Ryan, as you recommended, I created a simple batch script that calls the
editor with a switch [/newinstance] and then forwards on the remaining
arguments. This switch tells the editor to "force
the new instance", otherwise you get the behavior that I described in my
first message.

Here is the content of the batch script which I named myeditor.cmd and saved
in my PATH:

C:\Progra~1\JGsoft\EditPadPro6\EditPadPro.exe /newinstance "%*"

Hope this helps someone else, and thanks again for your assistance.

Josh Blair
Golden, CO
<josh.blair@gmail.com> <josh.blair@gmail.com>
On 6/4/07, Ryan Schmidt < subversion-2007b@ryandesign.com> wrote:
> On Jun 5, 2007, at 00:04, Josh Blair wrote:
> > I tried making EditPadPro.exe my SVN_EDITOR using the following
> > command line set command on WinXP SP2:
> >
> > set /P SVN_EDITOR=
> > C:\Progra~1\JGsoft\EditPadPro6\EditPadPro.exe
> >
> >  but when I try to do a 'svn commit', the EditPadPro.exe editor
> > pops up as expected and I save my comments, close the svn-
> > commit.tmp file after adding my comments like this:
> >
> > ===================
> >
> > - added unnecessary comment to test the SVN_EDITOR environment
> > variable being set to EditPadPro.exe
> > - removed the .user file from source control
> > --This line, and those below, will be ignored--
> >
> > M    Program.cs
> > D    HFXMLImporter.csproj.user
> >
> > ===================
> >
> > ...and the svn commit displays the following message:
> >
> > ==================
> >
> > C:\Projects\HFXMLImporter\HFXMLImporter>svn commit
> >
> > Log message unchanged or not specified
> > a)bort, c)ontinue, e)dit
> >
> > If I set the SVN_EDITOR environment variable back to notepad.exe ,
> > everything works properly.
> >
> > Any ideas?  Would it be the default encoding of EditPadPro or
> > something like that?
> You'll have to ask the authors of EditPad Pro, but I suspect that the
> parameters it accepts on the command line are not the same (or at
> least not in the same order) that Subversion sends them, or maybe you
> need to send some additional EditPad Pro-specific arguments.
> For comparison: to use TextWrangler as my editor on my Mac, I set
> EDITOR=editor.sh and I wrote editor.sh as follows:
> #!/bin/sh
> edit +1 --wait --resume "$@"
> The first line identifies this as a Bourne shell script. In the
> second line, "edit" opens TextWrangler, "+1" tells it to select the
> first line of the opened file, "--wait" tells the terminal to wait
> until TextWrangler saves and closes the file before proceeding, "--
> resume" tells TextWrangler to switch back to the terminal when the
> file is saved and closed, and "$@" passes along to TextWrangler all
> the arguments passed to editor.sh, which would be the filename. Maybe
> you need to make a similar wrapper script (but tailored to EditPad
> Pro's needs, whatever those might be).
Received on Thu Jun 21 15:44:48 2007

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.