subversion-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "David Dyer-Bennet" <>
Subject Re: Bug report -- space in env. var. VISUAL causes commits to fail (needs confirmation)
Date Tue, 07 Dec 2010 14:44:28 GMT

On Tue, December 7, 2010 04:18, Julian Foad wrote:
> On Tue, 2010-12-07, Daniel Shahaf wrote:

> I confirmed that there was a bug in that report, but that was on Windows
> and the evidence there was that the arguments were not being parsed
> correctly even when the space was escaped with the "^" character.
> That's a different problem from yours.

I'm also not sure what this concept of escaping with "^" is; if this is a
windows thing I've managed to avoid learning about it (and I still use
Windows systems, even today).

>> Today we use system(), and thus things like EDITOR='gvim -f' and
>> EDITOR='emacs -nw' work.  If propedit-cmd.c just quoted all spaces in
>> the editor command, it would break this use case.

Agreed, that would be too drastic a solution, and would break important

>> I suppose setting VISUAL="\"/path with spaces/to/editor/binary\"" is the
>> easiest solution --- it requires no code changes so it will work with
>> any svn binary out there.
> Yes, I think that's the best solution.

That's an interesting idea.

Unfortunately, it doesn't seem to work.  (Example from Centos 5.5 again):

sh-3.2$ export VISUAL='"/home/path with spaces/bin/emacs"'
sh-3.2$ echo $VISUAL
"/home/path with spaces/bin/emacs"
sh-3.2$ ls -l "/home/path with spaces/bin"
total 8
-rwxr-xr-x 1 root root 192 Dec  7 08:40 emacs
sh-3.2$ svn commit
basename: extra operand `spaces/bin/emacs'
Try `basename --help' for more information.
Can't find
svn: Commit failed (details follow):
svn: system('"/home/path with spaces/bin/emacs" svn-commit.tmp') returned 256

And, in any case, VISUAL is a public interface, and I wonder how many
other applications would break if I put that kind of thing into

David Dyer-Bennet,;

View raw message