3 ms·
Line numbering is the way you communicate when you're pair programming, and it's also the way tools tell you about errors - and not all of those tools are integ
by barrkel 13y ago
Line numbering is the way you communicate when you're pair programming, and it's also the way tools tell you about errors - and not all of those tools are integrated, or necessarily work best when integrated, with mode-aware buffers.
For example, I use pry and associated debugger stuff when working with Ruby. Want to set a breakpoint more precisely than a method? Need line numbers. Why would I not want that inside an emacs buffer? Because pry's symbolic completion is integrated with readline.
- jrockway 13y agoBreakpoints I agree with. Pair programming; I just describe the position in the program. Humans are much smarter than computers. "You see where you're catching FooError in Bar?" You can also use your finger to point. Anyway, I'm not saying you never need to know the line number, but I'm saying it's not the movement idiom in Emacs. In vi, all the motion commands take line numbers as arguments, so you use line numbers to navigate. In Emacs, the commands don't take line numbers as arguments, except for goto-line. (In this case, a leap of faith is necessary. Something tells you, error on line 42. So you tell Emacs to go to line 42. The line you are on now must be line 42. QED.)
- davidw 13y ago(global-set-key "\C-cg" 'goto-line) Is handy to navigate quickly to a line number.
- davexunit 13y agoThe current line numbers is visible in the modeline and you can use the goto-line to jump to a specific line. And you can always temporarily enable linum-mode if you really need to see all of the line numbers.