Live data from Hacker News

Vim after 15 Years

statico.github.io

71–80 of 176 posts

Re: Vim after 15 Years

#71

Vim is the best lightweight single file editor there is. That’s all it should be. If you’re heavily configuring it, you should be able to answer “why is this better than an ide?” Without saying “vim makes me cool”. Also, if you can answer that, please let me know! To me, an IDE is better for everything but what default vim is good at. And if you tell me that typing is faster, please also tell me why that’s relevant!

After you really internalize the Vim movement keybindings, using anything else to move, from arrow keys to home/end to the mouse, feels like an interruption in your workflow. The wrist movements are what kill you by a thousand cuts.

It's like TrackPoints versus mice. Once you're used to never leaving the home row, the alternative feels rough and unergonomic.

Re: Vim after 15 Years

#72
> TextMate and Sublime Text showed us that the fastest way to find a file is by fuzzy finding

Stopped reading here. This is from emacs and those other editors copied it. Emacs had this in about 1996, a full decade before those other editors existed. Oh, and the emacs versions are way more flexible than fzf due to supporting tab completion as well. All this other stuff has been in emacs for decades as well.

I know about the Holy War etc.. but seriously, credit where credit is due.

Re: Vim after 15 Years

#73
post #14

I'm an avid tmux+neovim user, too, though working with Reason is a lot easier in VS Code. Making the switch from actual vim to fake vim (ie JS emulation) sucks. Recently, VSCodeVim merged #1725 to add actual neovim as an editor - it's using NeoVim's embedding API so you're using neovim to edit the text file inside of VSCode's chrome, including all of VSCode's type hints and popups. Info here: https://github.com/VSCod…

This is the FIRST time when a "Emacs is a nice OS, all it's missing is a decent text editor" joke would be appropriate. If 20 years ago you would have told me we gonna have Vim inside a text editor inside a web browser I would have thought you are insane.

BTW, it does have a decent text editor. It's called Evil :)

Re: Vim after 15 Years

#74

"The vim-surround plugin is so useful that it should probably be built into Vim." I couldn't agree with this more. Also undotree [1] should be built into Vim as well. Vim represents undo/redo under the hood as a tree, which is absolutely incredible once you have a plugin that unlocks it, but the built-in facilities for traversing that tree could be charitably described as "dismal". Vim's undo tree makes a solved prob…

Here's an alternative to vim-surround mentioned on r/vim:

https://github.com/machakann/vim-sandwich

Re: Vim after 15 Years

#75

I had another pane autorunning something when it detected src file changes (inotify). So you just :w, and it happens. The method in this blog could do this: just add :w to the mapping. The blog method might seem hacky in using up and enter, but this makes it easy to modify the command you want to run.

If you use inotifywait a lot, I recommend trying http://entrproject.org/ which solves a lot of minor annoyances with inotifywait. It makes it easy to e.g. rebuild all web pages, restart your simplehttpserver and reload the current Firefox tab every time on of your `git ls-files` changes. The "restart server"-part can be fiddly with plain inotifywait, trivial with `entr -r`.

Nice! Currently, I use my own script [0] but entr is more general and supports more platforms.

[0] https://github.com/qznc/dot/blob/master/bin/git-onNotify

Re: Vim after 15 Years

#77
post #46

I would not remap , and ; as the article suggests, since those keys are already used in Vim for repeating f/F/t/T.

I have not heard any good argument for a leader key better than . f, t, b for fzf (and t is not a stretch on my keyboard layout)

You can't use space as leader in insert-mode?

Re: Vim after 15 Years

#78
post #53
post #15

Earlier quoted context omitted.

Switched to i3 a few weeks back and I absolutely love it. Switching between applications and workspaces is incredibly fast, and the _only_ time I need the mouse is for web browsing. It's amazing.

Firefox? Check out something like VimFX. No need for the mouse on 80% of the webpages.

Unfortunately it appears all of the most popular (and feature-complete) Vim-style plugins for Firefox are dying with the upcoming Firefox update dropping support for XPCOM/XUL plugins.

Re: Vim after 15 Years

#80

I was split between using Emacs and Vim for last 2 years (I used Vim for last 6, and learned Emacs 2 years ago). But what made Vim my main editor is fzf and ag, and smooth workflow that I had in terminal. But I have to say, ivy and counsel made my Emacs experience much, much nicer. But I guess that I got too deep into Vim already that I kinda got used to it so much, that I appreciated more that "terminal" workflow.

> I was split between using Emacs and Vim for last 2 years

You're going to have to pick a side. You can't be an atheist that dabbles in Catholicism.

Post reply on HN