Live data from Hacker News

Switching from Vim to Intellij

browntreelabs.com

171–180 of 263 posts

Re: Switching from Vim to Intellij

#171
post #30
post #10

What does the author mean by "setting up copy/paste? I've been using vim for about 20 years and just do "+y and "+p

I've found it to be a colossal pain in the ass in WSL, since the emulated linux clipboard isn't synced with the windows clipboard. I have to :wq, cat the file, and ctrl-ins to copy.

If you set up VcXsrv (an X-server) then your clipboard will be shared between WSL and Windows and Vim will work as long as you have +clipboard support in your copy of Vim without doing anything extra.

I made a video tutorial around setting it up at: https://nickjanetakis.com/blog/getting-copy-paste-to-work-in...

Re: Switching from Vim to Intellij

#172

Switching from a bicycle to a truck. Vim is NOT an IDE. Yes a lot of people try to make it one, but Vim is not very good at it. You need a lot of additional small tools to even come close to a full-blown IDE in functionality. It's a text editor.

Sure, an IDE comes with all the tools and features right out of the box. But not everyone needs all of them. I don't see a problem with combining tools, which is really easy with Vim as it already runs in the terminal.

I installed a couple plugins in Vim. But those all provide features I actually use and they barely affect performance. But more importantly I just prefer the Vim approach: start out with a minimal UI and feature set and only add or tweak what is needed. No weird and distracting auto-formatting while I'm still typing, more intuitive tabs/buffers and nothing running in the background all the time. I might be an outlier because most editors and IDEs have standard configs that I find distracting and frustrating, but I rather put a motor and bags on my bicycle than start cutting down a truck.

Re: Switching from Vim to Intellij

#173
>Everything is pre-configured: You don’t have to worry about setting up tags, or YouCompleteMe, or NERDTree. I can’t tell you how many times I open a new project, perhaps in a different language, and everything works great out of the box. It’s a total sigh of relief.

I agree 100% here, if you value these types of IDE tools I don't recommend going to Vim. It frankly sucks at this stuff, it wasn't meant for it and it's not the type of things you can easily tack onto a codebase not meant for it. Doesn't stop people from trying of course, and some do an amazing job at it, but it rarely reaches the same level of polish and simplicity as good IDE solutions.

But on the other hand, please consider the Zen of dumb tools: I code all day in Vim and I don't use YouCompleteMe, NERDTree or anything like that. I use dumb, language-agnostic completion and dumb, language-agnostic FZF and Rg for searching and navigating the source code. If I'm feeling fancy I use universal-ctags, but if it's not here FZF and Rg do a good enough job.

Is it as fancy and fully featured as an IDE? No. But like the author I like when stuff just works, and dumb tools work reliably regardless of what I'm editing. It works in emails, it works in man pages, it works in custom DSLs, it works in config files, it works in HN comments if I decide to edit them there. And it's always instant.

Re: Switching from Vim to Intellij

#175
post #125

Earlier quoted context omitted.

I'm the same way. The wires don't really seem to ever get crossed for me. When I'm using intelliJ, I honestly find that I'm not really typing all that much. I'm either reading/navigating code (and therefore ctrl-clicking on identifiers or using shortcuts for finding usages etc), or typing in a pretty linear fashion that is the sort of thing I'd be in insert mode for the entire block anyway. So when I spend most of my…

Piping into vim is new to me, thanks for the tip.

It's not just vim, either — most command-line tools let you write "-" where you'd usually write a filename, which tells them to use stdin as the file.

Re: Switching from Vim to Intellij

#177
post #165

Most important problem missed with fancy IDE: Tiny monitor. Its like looking at your source code thru a paper towel tube instead of in VR. Even if you can get a bigger monitor and give up on laptops, you'd STILL get to see more code at once using VIM. Its "nice" and "interesting" I can see my build system innards on the left and with effort I can click them in and out but in practice people are lazy and just don't ge…

With PyCharm I've managed to hide every single part of the UI besides the editor itself (I only had to get one plugin for the last bit, main menu toggler) and just use keybinds to show parts as I need them, so it's definitely a problem you can solve if you like

Re: Switching from Vim to Intellij

#178
post #165

Most important problem missed with fancy IDE: Tiny monitor. Its like looking at your source code thru a paper towel tube instead of in VR. Even if you can get a bigger monitor and give up on laptops, you'd STILL get to see more code at once using VIM. Its "nice" and "interesting" I can see my build system innards on the left and with effort I can click them in and out but in practice people are lazy and just don't ge…

When I use JetBrains I have three 27" monitors - one in portrait - and multiple files open simultaneously in all of them, plus build messages, file lists, and run logging. And (sometimes) the debugger.

For some projects I have different language environments - like CLion and PyCharm - open simultaneously. With a browser in the background for checking docs and StackOverflow.

I suppose I could do all of that in Vim too, but I'm not sure why I'd want to.

There are things I'd improve about JetBrains, not least the ability to effortlessly open the same project on different machines. Currently that's clunky for some languages.

But generally it's a damn fine product.

Re: Switching from Vim to Intellij

#179
> Everything is pre-configured: You don’t have to worry about setting up tags, or YouCompleteMe, or NERDTree.

I don't have to worry about any of that with Vim either. I have a dotfiles repo on github which I sync to any new machine I set up. There's a script inside which symlinks the configs and .vim directory into my homedir. I've been using this for 15 years with very minor tweaks. It works.

Re: Switching from Vim to Intellij

#180

Earlier quoted context omitted.

That's definitely a huge issue. I've had the same experience of having to spend hours to a day getting my configuration set up for a new language. I think part of the problem is that there's no basic config for a language (as with other editors) from which users can tweak, mostly because anyone who tried to get vim users to standardize on any defaults other than those shipping with vim itself would be strung up and h…

I was using ALE for autocompletion and such, but having switched to COC, I find its support for TypeScript to be far superior. This is relevant because COC is basically a system for talking to language servers. https://github.com/neoclide/coc.nvim

Yep, I too have switched to it and pair it with CCLS for my C/C++ development. It works great after learning it and does significantly reduce the overhead needed for new languages. It's a little tricky to set up for new users, but it's nice that things have improved so much.
Post reply on HN