Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Never reached being a vim power user. Somehow I always end back up to an IDE especially when it involves a bigger project. Could someone share some power user examples when only using vim it really shines for programming?


I use "recorded on the fly" macros all the time. But other than that, I use vim to avoid using an IDE as much as possible. I keep in the terminal, have all my tools available, don't have to click around or wait for load times, etc. Vim opens instantly and I can navigate to where I need to go instantly.

For instance, just yesterday, I had a test failed that was comparing two (big) classes of objects, and the test suite spits them out as single long lines as a diff.

But looking at long lines are super hard to read, so I can just do something once (ie: take a vertical chunk of text between zero and the next comma, and append it to end of file) then run that macro 70 times, and suddenly that long line I had to scroll through is all divvied up and I can easily spot where the issue is.

All of this is a bit simpler (believe me!) Compared to trying to remember where a certain menu item or action is. I'd probably have to pull up excel if I didn't have vim.

But you've heard this all before


I like Vim's editing model. Vim itself is a truly awesome piece of software. BUT - it doesn't have IDE style features, which I have come to rely on to do my job effectively, built in.

Luckily for me, Vim's editing model exists in the IDEs I use via Vim 'emulation' plugins. In Jetbrains IDEs and in VSCode, the emulation is quite good. In the incredibly rare instance where I need a macro or some similar 'power user' Vim feature, I just pop that file open in Vim.

For me this approach strikes the best balance. I get to use the powerful modal editing that I've come to enjoy, while also getting to take advantage of the many powerful features of IDEs.


IdeaVim by JetBrains does macros. Slower than Vim but still.


The best thing about Vim is that you don't have to choose between Vim and an IDE! Any text editor or IDE that's even moderately popular will probably have a decent Vim plugin. The only downside is that you generally won't have access to Vim plugins (abolish.vim is the one I find myself missing the most: https://github.com/tpope/vim-abolish).

Personally, I learned to use Vim via the VsVim plugin for Visual Studio.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: