Hacker News new | ask | show | jobs
by _0w8t 2017 days ago
Without plugins Visual Studio Code in principle is just an editor. Yet even without any plugins or language-specific support it still a better tool for development out-of-the-box than Vim or Emacs. It can quick open and search across a development tree with thousands of files with no configuration.

So as an editor for config files and small projects Vim without plugins is OK. But that basic Vim experience just does not scale. One does need plugins with Vim for anything big.

4 comments

I mentioned FZF (with Rg) with IMO is a great plugin to use. With it you can explore huge projects very quickly without requiring any language specific setup. Vim also supports tags files by default which can be quite nice when browsing large projects, just run universal ctags and you can cross reference symbols for most languages.

Actually the only project-oriented Vim plugins I use are FZF, editorconfig and fugitive (git interface). The rest are just editor tweaks such as vim-unimpaired and vim-surround. And I regularly deal with very large codebases such as the Linux kernel, so at least for my use case it scales reasonably well.

> Yet even without any plugins or language-specific support it still a better tool for development out-of-the-box than Vim or Emacs.

ⓘ This claim is disputed.

> It can quick open and search across a development tree with thousands of files with no configuration.

M-x find-grep would like a word.

Before you say anything, Visual Studio Code depends on (and bundles) ripgrep to do its fast searches. (Emacs defaults to using your system's grep.)

> It can quick open and search across a development tree with thousands of files with no configuration.

    git grep

?
Checkout chromium and try that on its tree. Or rgrep. Then try searching it with vscode and compare the timing especially with second and following searches. And vscode is smart enough to search files that where opened recently first bringing useful results instantly.
Of course if you need to cross reference the entirety of a gigaproject like Chromium you're going to need some sort of a cache and smart search. If I was a Chromium dev I'd probably set something up to help with that.

99.999% of source trees are a tiny fraction of that size however.

As I mentioned in another comment I routinely hack in the Linux kernel which contains about 15million SLOCs (per sloccount) and ripgrep takes less than 5s on a cold run and is near instant after that. ctags lookup almost instant regardless of cache. And that's on a 5 year old middle of the line SSD and CPU.

Inability to easily deal with chromium-sized repositories out of the box might be a deal breaker for you but it's a total non-issue for me.

> One does need plugins with Vim for anything big.

When a fresh shell tab is just a command-T/ctrl-T away, you don't need Vim to do any of these things in the first place. The point of Vim is that it's a text editor that lives in an environment where you can already accomplish everything other than text editing.

VSCode is a text editor that uses plugins to bring other programs into VSCode. Vim is a text editor plugin for an environment in which all those programs already run natively.

The problem with basic Vim is that it does not support out-of-the-box tools that can run longer than an invocation of a single command, like language servers, project indexers, tree synchronizers etc. ctags etc. just does not scale. And on Windows and to lesser extent on Mac one needs that even for medium-sized projects.