Sunday, February 20, 2011

viminfo: Missing '>' in line - and other wierdness

I talked a blind friend into using vim instead vi, and he would love the
benefits without the agonies. Recently, he got the message,

viminfo: Missing '>' in line - -

when opening and closing files. This message showed up in forums years ago,
and it was referred to as a `known bug in vim'. Only solution offered was to
delete the corrupt viminfo file. I did better, and discovered that viminfo
prefaces filenames and line numbers for bookmarks with a > character. Sure
enough, lines for his last two filenames lacked the > preface. When I inserted
it, the error messages disappeared.

Where can I learn the format used for lines inside the viminfo file?

Anyone know, specifically what causes this error? Was it fixed in recent
versions of vim?

I realize there are many things I dont know about viminfo. I believe the
history variable specifies how many items (of each type or total?) vim keeps
in memory during a session. The viminfo variable, I believe, specifies more
about how many things vim stores, when a session closes, and remembers when a
new session opens - complicated!

What happens, specifically, when you exceed one of these limits? For instance,
if you exceed the limit for capitol letter, persistent bookmarks, does vim
simply stop saving such bookmarks entirely? Or does it recycle, forgetting
mark A so you can set a new A? Does it give error messages for exceeded
limits? Might this ``missing `>' be an error message related to a limit?

My friend, innocently also moved a file he bookmarked. He was surprised vim
did not `realize' his unix OS did a mv command. Thus - how, if at all are
files tracked in viminfo? Do pathnames, once in viminfo last forever? Does
vim, somehow delete file and line information once its limits are exceeded?
Are their any ways to `reset' the viminfo file, or update its information -
except by just deleting the file? Can you `tell' viminfo to delete information
about fileis, and filenames?

--
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