(Insert TipProposed template + minor manual clean) |
(Change <tt> to <code>, perhaps also minor tweak.) |
||
Line 20: | Line 20: | ||
--><p>Under Windows 7, this is probably <code>c:\users\admin\AppData\Roaming\Subversion\config</code>.</p><!-- |
--><p>Under Windows 7, this is probably <code>c:\users\admin\AppData\Roaming\Subversion\config</code>.</p><!-- |
||
--><p>Surprisingly, TortoiseSVN doesn't do this by itself even though it's commonly described as required in order to have TSVN work over SSH. Edit the file and under the [tunnels] section, add this line:<br /><!-- |
--><p>Surprisingly, TortoiseSVN doesn't do this by itself even though it's commonly described as required in order to have TSVN work over SSH. Edit the file and under the [tunnels] section, add this line:<br /><!-- |
||
− | -->< |
+ | --><code><nowiki>ssh = $SVN_SSH "C:/Program Files/tortoisesvn/bin/tortoiseplink.exe"</nowiki></code></p><!-- |
--><p>Enter it that way verbatim (assuming you've installed TSVN in the standard location). The biggest hassle with all this is getting these command lines just so - it's incredibly sensitive to correct escaping etc.</p> |
--><p>Enter it that way verbatim (assuming you've installed TSVN in the standard location). The biggest hassle with all this is getting these command lines just so - it's incredibly sensitive to correct escaping etc.</p> |
||
#edit your _vimrc<!-- |
#edit your _vimrc<!-- |
Revision as of 08:20, 14 July 2012
Proposed tip Please edit this page to improve it, or add your comments below (do not use the discussion page).
Scenario: you have an existing svn working directory created with TortoiseSVN using the svn+ssh protocol, and you want to interact with it using version control commands within Vim.
In this case, the repository server is on a non-standard SSH port; to support this, a PuTTY named session is stored in the working directory meta-info. The following procedure will address this situation as well as a normally-addressed svn+ssh checkout.
Procedure
- Install the VCSCommand plugin as described on the script page. i.e. unpack the scripts to your plugin directory (probably
C:\Program Files\vim\vimfiles\plugin
). If you're only going to be using svn, you only really need vcscommand.vim and vcssvn.vim. - edit the subversion config file.
Under Windows 7, this is probably
c:\users\admin\AppData\Roaming\Subversion\config
.Surprisingly, TortoiseSVN doesn't do this by itself even though it's commonly described as required in order to have TSVN work over SSH. Edit the file and under the [tunnels] section, add this line:
ssh = $SVN_SSH "C:/Program Files/tortoisesvn/bin/tortoiseplink.exe"
Enter it that way verbatim (assuming you've installed TSVN in the standard location). The biggest hassle with all this is getting these command lines just so - it's incredibly sensitive to correct escaping etc.
- edit your _vimrc
Add the following two lines. In my case, my working dir was in c:\working. Adjust the value of the second variable according to whatever yours is.
let VCSCommandSVNExec="C:\\Progra~1\\TortoiseSVN\\bin\\svn.exe" let VCSCommandVCSTypeOverride= [['C:\\working\\*', 'SVN']]
Again, do the escaping just like that (particularly the 'progra~1' thing), or VCSCommand will refuse to work without offering any particularly helpful error messages.
Then save and close everything. To test, edit one of the files in your checkout. Try :CVSLog
and tortoiseplink should open a dialog prompting you for your repo password (assuming you authenticate via password). CVSCommand should then work as described in it's docco thereafter.