While there is no shortage of information on how to set a text editor for the Subversion Command Line Interface to use (see here, here, and here for example), I can't figure out where my local system is getting the text editor information from.
On my system, when I perform an svn commit, it opens vim for a commit message. Since this is what I want, I never really thought about it. This has always just worked. However, recently a co-worker was trying to commit, and it failed with an error saying the editor was not set. I never went out of my way to set an editor, so I am very confused about this.
I am running Ubuntu 12.04 and I have compiled and installed the Subversion CLI client version 1.8.10 from source code. Previous to that, I was using whatever Ubuntu's Canonical system installed with apt-get install subversion.
The Using External Editors section of the Subversion Book states the following possibilities for setting the text editor:
- --editor-cmd command-line option
- SVN_EDITOR environment variable
- editor-cmd runtime configuration option
- VISUAL environment variable
- EDITOR environment variable
- Possibly, a fallback value built into the Subversion libraries (not present in the official builds)
I have investigated these places and have not found how the default text editor is set on my computer:
- Not using
--editor-cmdoption when committing SVN_EDITORenvironment variable not seteditor-cmdis not set in either my~/.subversion/config, nor in/etc/subversion/config. Both of these files exist, but the line is commented out.VISUALenvironment variable not setEDITORenvironment variable not set- I'm downloading the official repository, so there should be no fallback.
There must be another place where the default can be set. Does anybody know?
Edit: There was a suggestion that Subversion might be calling /usr/bin/editor, and this is not set up on my co-worker's machine. I discovered that /usr/bin/editor is set up the same on both my system and my co-worker's system.
ltraceon yoursvncommand to find out. Perhaps thesvnbinary has something built-in; trystrings $(which svn)svn --versionsvn --versionon both machines reveals that they are both running Subversion version1.8.10../configure;make;sudo make installor something similar). What I am curious about is whether you specified any options for./configure. If you didn't use./configurehow did you build from source?