In case it’s not clear from my tone, I’m totally sympathetic to relieving injury, and whatever works, works. I just don’t understand how Vim bindings help, and am genuinely curious.
Yes! I very much do. I do not use the arrow keys for cursor movement in edit mode.
inoremap <Left> <NOP>
inoremap <Right> <NOP>
inoremap <Up> <NOP>
inoremap <Down> <NOP>
(the rest is at https://trout.me.uk/X11/vimrc)The purpose of insert mode is to insert text, and that’s it. This occupies a very small proportion of total editing time.
Speak for yourself! I do it all the time. Navigating by word is my primary means of moving through a line.
Maybe that’s why I’m happy to be free of vi. It was my primary editor for at least 10 years. And I’m happy to see the back of it.
> Navigating by word is my primary means of moving through a line.
So how does your new editor do that more efficiently than pressing <Esc> once, followed by pressing <w> or <b> once for each word?
Just to be super clear, I don’t care what other people do. Go nuts with vi bindings. I was just agreeing with what someone else said, that vi bindings aren’t peak UI and that “hacker” != “vi”
Now we found out that leaving insert mode to navigate by words requires the "same number of keys", so @gsinclair was right and it is unnecessary to stay in insert mode for navigation.
> Same number of keys, but works pretty much everywhere. The box used to enter this comment, for example.
If efficient word navigation was the only thing vim key bindings had to offer I wouldn't be using them. But they do offer many things the current text box does not offer and since (as a programmer) I'm spending 95% of my time in an IDE and not some browser text box, I'll gladly accept some inconsistencies if that means editing and navigating in my IDE becomes more pleasant.
I’ve been using it for so long that apparently the muscle memory is the only memory I have.
I mean thinks like yy and p and ZZ sure, but for navigation I know where on the keyboard it is - but not the keys. (At least not while I’m using an iPhone keyboard)
Aren’t brains weird?
I was definitely on team vi in the Great Emacs Wars, but it’s not my preferred way of editing any more. Nevertheless it’s something that I know quite well, and this conversation has really opened my eyes to the idea that this sort of thing can help people.
I started with vi eons ago because it was easier to use it remotely to do my school work than it was to walk into the labs and use a graphical editor. The habit stuck -- vi has a steep learning curve, but it's also habit forming, so to a large degree I use vi because of the habits I developed.
However, when pain from ulnar deviations began to set in I had to experiment and research to find something that worked, and that was sticky keys, and I've not been in pain since. The fact that I didn't have to give up vi certainly says something, namely: that vi wasn't the cause of the injury. But also now that I understand what caused the pain (ulnar deviation), I shudder to think of using emacs.
> Do you know others in your situation who use vi bindings?
I do not, though I do very much recommend using sticky keys.
I have taught my son how to use vi and he loves it. Like I said, vi is habit forming, but good habit forming :)
I’ve used vi since at least the early 1990s. I still use it today, but I really do prefer a non modal approach to editing and always have.
That said, of course, I wouldn’t be caught dead using nano :P
> That said, of course, I wouldn’t be caught dead using nano :P
ISTR that Rachel by the Bay uses nano. No shame in that!