sponsor Vim development Vim logo Vim Book Ad

VimLocalHistory : Automatic backup and poor man's revision control.

 script karma  Rating 28/7, Downloaded by 509  Comments, bugs, improvements  Vim wiki

created by
David JH
script type
VLH automatically saves buffers on write using git.  This provides a convenient, automatic backup system of, e.g. files in /etc that are modified, as well as a poor man's "local history" (a lá the eclipse feature with the same name).

Feedback, bug reports and suggestions gratefully accepted at <vlh@hjdivad.com>.

To use, install, configure g:vlh_repository_dir and then use vim normally.  Every time you write a buffer whose path is on the local filesystem, a copy is saved in a git repository.

You can open, diff or restore older versions of files with the commands VLHOpen, VLHDiff and VLHReplace.

source code is available from github at http://github.com/hjdivad/vimlocalhistory/tree/master
install details
To install from a tarball:

After ensuring that you meet the requirements, copy the contents of
plugin to user-specific vim plugin directory, probably ~/.vim/plugin/

To install documentation, copy README (this file) to your vim
documentations directory, such as ~/.vim/doc/vlh.txt.  After copying
the documentation, execute ":helptags ~/.vim/doc" from within vim to
make the documentation accessible.

To install from source:

Install the requirements, additionally installing rake version 0.8.1
or higher, and then execute

rake install

which will install the plugin and documentation.

Once VLH is installed, make sure to edit your ~/.vimrc to include

let g:vlh_repository_dir = "/path/where/youd/like/to/store/localhistory"

I suggest using ~/.vim/localhistory.


rate this script Life Changing Helpful Unfulfilling 
script versions (upload new version)

Click on the package to download.

package script version date Vim version user release notes
vimlocalhistory-0.2.tar.gz 0.2 2008-11-15 7.0 David JH Initial upload
ip used for rating:

If you have questions or remarks about this site, visit the vimonline development pages. Please use this site responsibly.
Questions about Vim should go to the maillist. Help Bram help Uganda.
OSDN.net Logo