Tuesday, February 1, 2011

Re: Help, please

> I apologize for being ornery. I have had to deal with Windows and AT&T
> lately. I will do better.

Heh, either Windows or AT&T alone is enough to boil one's blood,
so I can sympathize and appreciate the occasional bad day. :)

> I'm aware of most of the options in vim. I'm not aware of any
> option to put the swapfiles elsewhere. That would also work.

Vim does provide the 'directory' option

:help 'directory'

which can be used to put the swapfile in the first directory in
the listing. For warnings, read below

:help E326

on the advantages/disadvantages to changing this. The only times
I've used this was back when floppy-drives were the norm, and
having a swapfile on a floppy was agonizingly slow.

You might make a compromise with some autocmds that will
set/restore 'directory' only if you're editing files in your
Dropbox dir.

> Then and only then, can I safely ignore the lock file and remove it.

I've occasionally wished for a "--wtf" option to vim that would
effectively open both the unrecovered and recovered versions in a
diffsplit allowing me to compare them. Currently I have to

1) open the file with "-r" to recover
2) write the file to a temp file
3) quit vim
4) delete the swapfile (remembering "/a" on Dos/Win32)
5) vimdiff the original and the temp file
6) make any fixes and save the file back out
7) delete the tempfile

Some easy means to do steps 1-5,7 would be most welcome.

-tim

--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

No comments:

Post a Comment