Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Line numbers in all emacs buffers

Tags:

emacs

I want to make that would in all the buffers which I had opened were line numbers in GNU/Emacs. In my .emacs i try to add:

(linum-mode t)

but it's not helped me.

Thank you

like image 214
0xAX Avatar asked Dec 12 '25 04:12

0xAX


2 Answers

Try with that in your .emacs:

(require 'linum)
(global-linum-mode)
like image 65
Cedric H. Avatar answered Dec 15 '25 17:12

Cedric H.


You can also customize the line number format, using printf style formatting.

eg. %5d for 5 char padding.

M-x customize-group RET linum RET for all the options.

like image 37
ocodo Avatar answered Dec 15 '25 16:12

ocodo



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!