Live data from Hacker News

Learn Vim (2021)

github.com

71–80 of 215 posts

Re: Learn Vim (2021)

#71
post #26
post #12

Earlier quoted context omitted.

I learned vim when I picked up linux, now I work at a company with a customized emacs tool we have to use. Doh it never ends...

If you develop RSI from emacs, you could have the employer make reasonable accommodations, i.e. let you use Vim :)

Emacs pinky can be a bitch

Re: Learn Vim (2021)

#72
post #26
post #12

Earlier quoted context omitted.

I learned vim when I picked up linux, now I work at a company with a customized emacs tool we have to use. Doh it never ends...

If you develop RSI from emacs, you could have the employer make reasonable accommodations, i.e. let you use Vim :)

Or use Evil mode :) I don’t think I can ever give up Org-mode. Vim-wiki, etc just can’t seem to sate that itch.

Re: Learn Vim (2021)

#73

I defaulted to Nano when I picked up linux, and that unfortunate choice has bitten me in the butt.

Having only used Nano since picking up Linux 2 years ago, I’m not sure what I’m missing. Can you make a case for me to learn Vim?

One thing I like about Vi vs other editors even for non full fledged development experiences like editing config files, is that Vi allows very surgical edits to change only what you want and nothing else.

You can easily control exactly what portion of the line or file you are making the edit to, and Vi will not allow you to change beyond that area without a further intentional command.

Re: Learn Vim (2021)

#74
post #27

Earlier quoted context omitted.

> Can you make a case for me to learn Vim? If you're coming from nano, I'd point to: 1) UI improvements like better syntax highlighting, split windows and tabs, and mouse support. 2) A cohesive language of key bindings that allows you to easily construct and perform commands like "delete everything from the cursor up to the next quotation mark" or "lower-case this paragraph". 3) A huge library of scripts and extensio…

Usually when nano is mentioned, it’s not a full development context, but instead e.g. crafting a systemd service file or editing crontab on a remote server. Do you really pull extensions and use mouse there? I think there’s nothing important that vim could add for gp, realistically. Speaking as a life-long vim user.

You probably wouldn't install all your extensions on a remote server, correct, but you get the basics like syntax highlighting and mouse support by default nowadays. Even a minimal vim install is considerably more featureful than nano.

Re: Learn Vim (2021)

#75

Earlier quoted context omitted.

And for those who don't know, on most modern Linux-based distributions `vi` is an alias for `vim` which is Vim (Vi IMproved).

True scotsmen exclusively use ed.

A lot of commands in ed also work in vim's ex mode. In fact, ex is an extended version of ed and vi is the visual mode for ex.

Re: Learn Vim (2021)

#76

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, you're interrupting your flow with what you consider mundane. That you consider text editors mundane is more reason to move as much of that process into muscle memory as possible, not less!

Why are we pretending like mastery of our tools is unimportant? I hear this sort of opinion most eagerly expressed by engineers who in fact are quite handy with vim! Is this some new kind of flex where we're all pretending to take a purely academic approach to programming instead of becoming proficient with the tools of our trade?

Re: Learn Vim (2021)

#77
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 is natural. Not better, just natural.

At the same time, I don't utilize it to its full strength. I probably do things that seem laborious to some, but no big deal to me.

Re: Learn Vim (2021)

#78

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…

I feel like at a certain point of efficiency there are diminishing returns. A good analogy is typing speed. You don't need to have 200 wpm to be productive. Everybody adapts to how efficient they need to be at what they do. Vim is not a requirement for being productive. If it was, it would be the most popular editor. I also don't think the person you are replying to is saying that it isn't important to "master" your tools. I think they are just saying the editor that you use isn't the most important thing and I agree with that sentiment.

Re: Learn Vim (2021)

#79
post #8

Earlier quoted context omitted.

Use neovim or astrovim or spacevim These are setup perfectly and come with just the right batteries installed

LunarVim is a good choice as well, just works out of the box

What's lunarvim what are it's advantages over space or ASTRO Vim

Re: Learn Vim (2021)

#80
post #9

Earlier quoted context omitted.

AFAIK is not fully compatible with Vim keystrokes

Correct. If you've got no background in vim, it might be a good thing Helix has broken "backwards compatibility" in order to have more cohesive key-bindings.

Yes my problem with helix is when the keystrokes that are muscle memory in Vim don't have any actions in helix this makes it problematic to move to helix

over moving to neovim for example neovim retains most if not all the vi keystrokes not just out of respect to the vi authors

Post reply on HN