Skip to content

A vim plugin for code annotation and code understanding using folds

Notifications You must be signed in to change notification settings

omairabdullah/vim-annotate

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

12 Commits
 
 
 
 
 
 

Repository files navigation

vim-annotate

A vim plugin for annotation using folds

Usage

Annotate a range of text by using the :Annotate command.

e.g.:

    :2,3Annotate "My annotation line"
    :'<,'>Annotate "Annotation of visually selected text"

This creates a fold for the selected range and replaces the foldtext with the text input by the user. This is really useful when reading code, as you can fold blocks of code with your own annotations. These annotations are saved and can be later restored (refer docs).

Screenshots

vim-annotate_before To annotate, select a range of text and call :Annotate.

vim-annotate_after The selected text is folded with the given annotation as the foldtext.

Installation

I recommend using a plugin manager to install this plugin. Vundle, Pathogen and NeoBundle are all really good plugin managers. Otherwise, unzip the zip file to your .vim directory.

Create a folder to hold the annotations and add a line to your .vimrc to setup the annotations folder.

let g:annotate_annotations_folder = <path to annotations folder>

Once setup, you can use the exposed :Annotate command on any range of visually selected text to make your annotation.

The annotation will be visible as the foldtext whenever that fold is closed.

About

A vim plugin for code annotation and code understanding using folds

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published