How do I enable line numbers to be displayed in Vim?
To enable line numbering:
To disable it:
And if you want it to apply to every instance of Vim you open... put
set number in your
I find it extremely useful to have a binding to toggle line numbering (among other things). It can be configured as follows
nnoremap <Leader>gn :setl number!<CR>:setl number?<CR>
The first command will toggle the line numbering for the current buffer (local) and the second one will display the current value of the option on the status line.