git clone 'git://github.com/coldnew/linum-relative.git'
display relative line number in emacs.
linum-relative lets you display relative line numbers for current buffer.
If you have
emacs24 installed, simply type:
M-x package-install linum-relative
And add the following to your .emacs
The non-interactive function linum-on (which should already be built into recent GNU Emacs distributions), turns on side-bar line numbering:
and alternatively, by enabling
Relative line numbering should already be enabled by default (by installing this package), following linum-on or enabling linum-mode. One can also use the lineum-relative-toggle interactive function to switch between relative and non-relative line numbering:
Toggle between linum-relative and linum.