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

Re: "svn commit" and EDITOR=gedit

From: Ryan Schmidt <subversion-2008c_at_ryandesign.com>
Date: Fri, 3 Oct 2008 16:48:56 -0500

On Oct 3, 2008, at 9:56 AM, Jason M. Sullivan wrote:

> Kris Deugau wrote:
>> Matthieu Moy wrote:
>>> The problem is a user who want to use gedit to write commit messages
>>> for SVN. The obvious first try is "export EDITOR=gedit", but
>>> gedit it
>>> too clever for that: if an instance of gedit is already running,
>>> then
>>> gedit acts as a client, asks the running instance to open the file,
>>> _end exits immediately_. svn thinks the user is done with the
>>> edition,
>>> and complains about an empty commit message.
>>> I google'd a bit, but "gedit svn" tells me a lot about the SVN repo
>>> for gedit, but much less about solving my problem :-(.
>> This isn't really a Subversion issue, but I ran into this same
>> problem from a different direction.
>> Change the EDITOR value to "gedit --new-window" to kick gedit into
>> opening a new window. man gedit may also show you a more suitable
>> option if your user doesn't like that.
> That just opens up a new window, and still exits immediately, so
> the problem is the same. (at least, on my machine that's what it
> does).
> The 2006 summer of code project SingleInstance seemed to be the
> right direction to solve this problem, but it looks like the
> project stalled out...
> http://live.gnome.org/SingleInstanceApps

I am not familiar with gedit, but to support this properly, it
obviously needs to not return control to the shell until the file
being edited is saved and closed. You'll have to look through the
gedit options or ask its developers to see if they have this option.

For comparison, I edit my Subversion log messages with TextWrangler
on Mac OS X. I set EDITOR to a simple shell script which contains:

edit +1 --wait --resume "$@"

These options are specific to TextWrangler, but tell it to

+1: put the insertion point on the first line when opening the file
--wait: wait for me to close the file before returning control
--resume: switch back to the Terminal when I close the file

To unsubscribe, e-mail: users-unsubscribe_at_subversion.tigris.org
For additional commands, e-mail: users-help_at_subversion.tigris.org
Received on 2008-10-03 23:49:19 CEST

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.