Actually I'm more interested in seeing this guy's tmux config file.
Numbers.vim - better line numbers for vim
21–30 of 47 posts
Re: Numbers.vim - better line numbers for vim
#22Actually I'm more interested in seeing this guy's tmux config file.
Re: Numbers.vim - better line numbers for vim
#23Re: Numbers.vim - better line numbers for vim
#24I know some people like line numbers, but personally, I just look at the status bar at the bottom of the buffer. I find line numbers on the side clutter up my view too much. I always use 80 character terminal widths, to make it easier to stick to my PEP8 validation script we run.
I use a pretty large font size for my terminal, and the extra 8 columns finally allows for two 80 column vertical splits on my laptop. Thanks for the suggestion!
Re: Numbers.vim - better line numbers for vim
#25Do you really need a plugin for this? If you want relative numbers to appear when in normal mode, and absolute line numbers to appear otherwise (e.g., when the window has lost focus), just throw this in your .vimrc: set rnu au InsertEnter * :set nu au InsertLeave * :set rnu au FocusLost * :set nu au FocusGained * :set rnu Here's a gist for posterity. Feel free to fork it, leave comments on what should be changed, etc…
I just have this in my .vimrc which lets you toggle it whatever way you want in edit mode and it stays however you leave it when you toggle modes " use Ctrl+L to toggle the line number counting method function! g:ToggleNuMode() if(&rnu == 1) set nu else set rnu endif endfunc nnoremap :call g:ToggleNuMode()
Re: Numbers.vim - better line numbers for vim
#26 10 i = i + 1
20 PRINT i
30 IF i > 100000 THEN i = 0: GOTO 10
40 IF INKEY$ = "" THEN 10
50 PRINT "Bible, Line:", i
http://www.losethos.com/files/BIBLE.TXTGod says... Line:16099
evil, they shall go in thither, and unto them will I give it, and they shall possess it.
1:40 But as for you, turn you, and take your journey into the wilderness by the way of the Red sea.
1:41 Then ye answered and said unto me, We have sinned against the LORD, we will go up and fight, according to all that the LORD our God commanded us.
And when ye had girded on every man his weapons of war, ye were ready to go up into the hill.
1:42 And the LORD said unto me, Say unto them. Go not up, neither fight; for I am not among you; lest ye be smitten before your enemies.
Re: Numbers.vim - better line numbers for vim
#27Earlier quoted context omitted.
That's fine for determining what line you're on, but visible line numbers make it much easier to jump to a particular line. I've only recently set number in my .vimrc and wish I'd have done it sooner.
I do that by jumping to the particular line. : or G does that.
Re: Numbers.vim - better line numbers for vim
#28Its these kind of things that I wish to see vanilla vim shipped with, without bothering the user much. Yes you can toss some commands and code snippets at me and ask me to use them to get these features. But not having to type commands/snippets and have all goodies out of the box is what modern text editors like sublime text are all about.
Re: Numbers.vim - better line numbers for vim
#29Earlier quoted context omitted.
I do that by jumping to the particular line. : or G does that.
I think the point is that it's harder to see what line number you want to jump to if you don't have line numbering on. . . .
Re: Numbers.vim - better line numbers for vim
#30Do you really need a plugin for this? If you want relative numbers to appear when in normal mode, and absolute line numbers to appear otherwise (e.g., when the window has lost focus), just throw this in your .vimrc: set rnu au InsertEnter * :set nu au InsertLeave * :set rnu au FocusLost * :set nu au FocusGained * :set rnu Here's a gist for posterity. Feel free to fork it, leave comments on what should be changed, etc…
I just have this in my .vimrc which lets you toggle it whatever way you want in edit mode and it stays however you leave it when you toggle modes " use Ctrl+L to toggle the line number counting method function! g:ToggleNuMode() if(&rnu == 1) set nu else set rnu endif endfunc nnoremap :call g:ToggleNuMode()