On Jan 18, 9:56 am, Gary Bickford <[email protected]> wrote: > Back in the day, on the Perq workstation, the text editor had a very > handy feature. It retained a transcript file for every change made to > a file, from the time it was created. The transcript could be > deleted, and then from then on it would retain the changes made since > that point. >
It's not per-file, but the -w startup flag will record the entire Vim session. That may give you a start. Recording every single keystroke is not something in the scope of what a plugin can do, but it might be possible to write a plugin that assumes the -w flag, and somehow parses the script out on a file-by-file basis on a VimLeave autocmd. You could call the parsing function manually in the case of a crash. But, this would probably be a pretty difficult plugin to make. You'd be better off with a different approach I think. For the first use case you describe, Vim's swap files and recovery mechanism will probably serve you better. This should "just work" by default. See :help crash-recovery For the second use case, if you have not yet exited your Vim session, you can use undo/redo and the undo tree (:help undo-tree). If you want persistence between sessions, you'll need to patch and recompile the Vim source code with the "persistent undo" feature. It's #4 on the list at http://groups.google.com/group/vim_dev/web/vim-patches
-- You received this message from the "vim_use" maillist. For more information, visit http://www.vim.org/maillist.php
