Live data from Hacker News

Learn Vim (2021)

github.com

91–100 of 215 posts

Re: Learn Vim (2021)

#91

It's kind of weird to read about "learning" VIM, at least from someone who's been using it (er VI) for 40 years. It's nuts, but if asked, I don't even know how to do certain things in VI; I just do them. Ask me what keys to press to go up, or down, or right or left? I dunno - I just do it. Yea it's nuts. It's like baby duckling bonding - the first editor mindset (aka EMACS vs VI) you use, you just bond to and it just…

Ha this is so true. I wrote in a comment elsewhere in this thread that I mostly just use the movement keys hjkl with a fast key repeat. But I'm still kind of wondering whether the movement keys are actually hjkl, because I'm writing this on my phone so I can't check whether those are actually the keys I use to move around, and I haven't actually thought about it in like a decade.

Re: Learn Vim (2021)

#92
post #57

Earlier quoted context omitted.

Unfortunately there is no ecosystem. Helix does not provide an extension interface.

That is too bad. If they did then they would probably garner huge community support and the gaps would be quickly filled in.

They're actively discussing/working on it: https://github.com/helix-editor/helix/discussions/3806

Re: Learn Vim (2021)

#93
Does anybody have a good wysiwyg word processing approach using vim keybindings? Editing markdown docs as plaintext is not as good for writing prose as I would like, but editing documents without vim keybindings is also unpleasant for me.

Re: Learn Vim (2021)

#94

Does anybody have a good wysiwyg word processing approach using vim keybindings? Editing markdown docs as plaintext is not as good for writing prose as I would like, but editing documents without vim keybindings is also unpleasant for me.

Emacs + Evil Mode + Org Mode + Org Mode Customizations

Google for „Emacs from scratch“ which will guide you through.

Re: Learn Vim (2021)

#95

It's kind of weird to read about "learning" VIM, at least from someone who's been using it (er VI) for 40 years. It's nuts, but if asked, I don't even know how to do certain things in VI; I just do them. Ask me what keys to press to go up, or down, or right or left? I dunno - I just do it. Yea it's nuts. It's like baby duckling bonding - the first editor mindset (aka EMACS vs VI) you use, you just bond to and it just…

Slight tangent, but what's with the capitalization of VI and VIM?

You surely know those are not acronyms, yet I've seen VIM miscapitalized many times, even by experienced users, and it's always slightly irritating.

EMACS, while historically accurate, also isn't common anymore.

Re: Learn Vim (2021)

#96
I'm using vim for 10 years and I know I have a lot of "bad" habits that I'm trying to eliminate, but it's hard. For example:

1. instead of doing 4j I might do jjjj

2. if I'm in the middle of a word and want to change it, I'll do bcw instead if ciw

3. if I want to copy 3 lines, I'll do Shift-V+jjj+ESC, instead of just 3yy

4. (possibly other 100 items here...)

But I find it very hard to change those habits. Anyone else struggling with this? Any tips to share in case you managed to get rid of them?

Re: Learn Vim (2021)

#97

I dunno, I never sat down to learn vim, just used it every day for a couple years. I’m not one of those wizards who is, like, answering stack overflow questions or writing wiki articles, but I get the job done. Is it necessary to learn Vim? Seems like a chore. Is the text editor really a bottleneck for anyone? I find that no matter how slow I type, I need to spend more time thinking of what to type anyway, if I’m doi…

I don't understand this attitude. It's clearly more conducive to solving problems to be able to move around our environment more quickly. It's extremely useful (compared to a beginner who only knows insert and write quit) to understand the different vim modalities as well as a few commands to jump around a file or to perform regex or to call an external command. When you're not proficient with the necessary tools, yo…

It is not about only Vim as editor but Vim as keybindings too. Nowdays, most of all modern IDEs support Vim keybindings along well integrated IDE features.

Re: Learn Vim (2021)

#98

I'm using vim for 10 years and I know I have a lot of "bad" habits that I'm trying to eliminate, but it's hard. For example: 1. instead of doing 4j I might do jjjj 2. if I'm in the middle of a word and want to change it, I'll do bcw instead if ciw 3. if I want to copy 3 lines, I'll do Shift-V+jjj+ESC, instead of just 3yy 4. (possibly other 100 items here...) But I find it very hard to change those habits. Anyone else…

For 1, I use https://github.com/ja-ford/delaytrain.nvim (for nvim only); it basically stops repeated navigation keys from working for a short while.

Re: Learn Vim (2021)

#99

I'm using vim for 10 years and I know I have a lot of "bad" habits that I'm trying to eliminate, but it's hard. For example: 1. instead of doing 4j I might do jjjj 2. if I'm in the middle of a word and want to change it, I'll do bcw instead if ciw 3. if I want to copy 3 lines, I'll do Shift-V+jjj+ESC, instead of just 3yy 4. (possibly other 100 items here...) But I find it very hard to change those habits. Anyone else…

Me too, after 18 years!

A decade ago I decided that I should probably learn the idiomatic way to do things and went through different learn-to-vim tutorials but none of it ever stuck. I finally decided that the way I use vim is the way I use vim, and when I can’t figure out how to do something and can’t do it with another tool, I’ll learn a little more which may or may not be retained.

There’s a mountain of things vim can do and adding plugins on top of that makes it a never ending climb that I’m happy to climb as I need too.

That doesn’t really answer your question, except to say, me too, and that I’ve just let it go. (And vim is compete’s with a web browser as the program I spend the most time in).

Re: Learn Vim (2021)

#100

I dunno, I never sat down to learn vim, just used it every day for a couple years. I’m not one of those wizards who is, like, answering stack overflow questions or writing wiki articles, but I get the job done. Is it necessary to learn Vim? Seems like a chore. Is the text editor really a bottleneck for anyone? I find that no matter how slow I type, I need to spend more time thinking of what to type anyway, if I’m doi…

What vim can do that emacs often is a little too slow for and IDE:s can't is to have finished even quite complicated incisions and changes to your text before you've become conscious that you asked it to do the thing.

This means it can help keep out intrusions about editor maneuvering from your mind at work.

Some people see no value to this and fill their vim bundle with plugins that slow everything down a lot, but some of us really enjoy just surfing the high source and watching our thinking materialise on the screen seemingly effortlessly and immediately.

I use IntelliJ all day every day too, but it's mainly for admin and control stuff and certain types of refactors it can handle better. It's to my code editing as gitk is to my version control. It's where I run the tests, all the plugins, can get docs prerendered, things like that.

It's not where I can quickly navigate the code base, jumping immediately from file to file as fast as a fuzzy hint can get me, and then within the file as fast as Space+string can get me. You might have a keyboard layout with a forward slash easily available, mine doesn't so in normal mode space is /. Navigating in vim can be hjkl w b and so on, sure. But it can also be search. Just say the place and poof, you're there. It's wrong but very similar to where you want to go? n for next or try to name a new place.

This doesn't work in IntelliJ and it's a little off in emacs. I mean you can certainly technically do it but it's slow. There's waiting and the application twitches when it tries to imitate the vim way. Pretty much all finding tasks can be powered by fzf and ripgrep, and unlike IDE:s vim just does the thing when you tell it to. There's is no wait and then a dialog, there is none of 'ok, understand but Ide competent, knows many things, need more info before can do the thing' that tools like IntelliJ and Visual Studio do.

You also want jk to be Esc for sure. Esc is far away and CapsLock is for Control.

Post reply on HN