I’ve learned some vi, and emacs, Visual Studio, VS Code, XCode, IntelliJ, and Android Studio. All the examples listed are pretty uncommon or trivial in any of the other IDEs (aside from the regex part, which is cool, but I never want to be in a place where I have to regex my code...ever). 90% of the time I’m doing simple code maintenance, with an occasional refactoring. And I know devs that swear by vi...they are dev…
> And I know devs that swear by vi...they are developing any faster than I am I hear about this from time to time, but have never seen it people do it successfully first hand, what I do see is silly mistakes in their checkins; incomplete variable renames, formatting is off, syntax errors, switching between browsers and their code while looking at manuals, or other obvious mistakes that can be caught inline by IDEs wh…
Why Vi Rocks
41–50 of 80 posts
Re: Why Vi Rocks
#42I've been using Neovim consistently for the last few months and it's a game-changer. Terminals within Neovim that I can paste into/from my Vimwiki files or source files is amazing. It's not very different from a Vim setup and using it with the Qt GUI on Windows gets rid if the issue of having everything close when eventually having to call . Meanwhile, in my linux environment it runs like a charm on a terminal.
Same here neovim with session management and tmux with session management, with tmux russerect and tmux continuum. And with the language server integration in neovim, its a swiss army knife that works well with most modern languages and devops.
Re: Why Vi Rocks
#43I’ve learned some vi, and emacs, Visual Studio, VS Code, XCode, IntelliJ, and Android Studio. All the examples listed are pretty uncommon or trivial in any of the other IDEs (aside from the regex part, which is cool, but I never want to be in a place where I have to regex my code...ever). 90% of the time I’m doing simple code maintenance, with an occasional refactoring. And I know devs that swear by vi...they are dev…
> but I never want to be in a place where I have to regex my code...ever). I use regex search and replace fairly often; why are you so opposed to it? If I need to change $t1 into t1 in a group of 6 lines (something I did today), its pretty easy to just make that replacement automatically. Doing it by hand would just take longer. > ... with an occasional refactoring That's exactly what I use the feature for.
Re: Why Vi Rocks
#44i see people struggling, fighting with Intelli-J every day. I wish I could give them vim as a gift. All the extra stuff you think you can't possibly give up you don't need. I'm a professional text file editor. Vim is like playing the piano. I guess what I'm saying is learn to play the piano for real, and don't spend your life in a piano-player-helper IDE thing.
Vim is a fantastic text editor, but it is not an IDE replacement. Here's just a few IntelliJ features I use daily that Vim doesn't have: Go to declaration, find usages, rename method/class, change method signature, auto-import, shortcut to override method, easy-to-configure style rules, really good code completion, quick access to javadoc. I could keep going. Again, not hating on Vim. I use Vim keybindings in Intelli…
>> Here's just a few IntelliJ features I use daily that Vim doesn't have: vim is intended to work with an operating system. The following assumes C or C++ since that's what I use. Maybe someone will find this list of equivalents useful? 1. Go to declaration: I use ctags which is built into vim. clangd can do better, but I've never bothered. 2. find usages: ctags also has support for this I think. 3. rename method/class: I haven't needed to rename something that wasn't exclusively in one file yet, but I expect clang-rename works well. 4. change method signature: not sure what this does. If it's just changing the declaration of the function, that seems pretty easy. ci( 5. auto-import: This one seems harder to get, but I never noticed it wasn't there. For in-project stuff, I just jump to definition. For standard library stuff, it's standard library. 6. shortcut to override method: I don't do much inheritance, so I never really noticed. This seems pretty easy to do a hack job with a macro and jump to definition. 7. easy-to-configure style rules: clang-format 8. really good code completion: basic autocomplete is built into vim. clangd is probably pretty good, but I don't usually need autocomplete. 9. quick access to javadoc: cppman is pretty good. https://stackoverflow.com/questions/2272759/looking-up-c-doc...
Maybe the state of tooling for Java isn't as openly accessible outside of an IDE and isn't as good for vim as C++? If using an IDE works well for you, great. I like using vim because it's lightweight, has good support for different file endings and large files, scales to any size code base I've encountered, and it gets out of my way. I feel like it's optimized enough that my brain is the limiter.
Re: Why Vi Rocks
#45I’ve learned some vi, and emacs, Visual Studio, VS Code, XCode, IntelliJ, and Android Studio. All the examples listed are pretty uncommon or trivial in any of the other IDEs (aside from the regex part, which is cool, but I never want to be in a place where I have to regex my code...ever). 90% of the time I’m doing simple code maintenance, with an occasional refactoring. And I know devs that swear by vi...they are dev…
> And I know devs that swear by vi...they are developing any faster than I am I hear about this from time to time, but have never seen it people do it successfully first hand, what I do see is silly mistakes in their checkins; incomplete variable renames, formatting is off, syntax errors, switching between browsers and their code while looking at manuals, or other obvious mistakes that can be caught inline by IDEs wh…
Re: Why Vi Rocks
#46* Eclipse - Forced to use this in University in the early aughts. I would say that crashing and clobbering systems was its best feature. You moved your mouse it crashed; thought about saving crash; need an update, now you need to format and clean install windows; want to print, printing works! want to compile, your gonna need to try again after restarting windows...
* SSH - In University we had some awesome terminal servers that were a joy to work with. I could access all my work from anywhere, regardless of how limited my local machine was. Vim was always there, chugging right along.
Re: Why Vi Rocks
#47Earlier quoted context omitted.
> but I never want to be in a place where I have to regex my code...ever). I use regex search and replace fairly often; why are you so opposed to it? If I need to change $t1 into t1 in a group of 6 lines (something I did today), its pretty easy to just make that replacement automatically. Doing it by hand would just take longer. > ... with an occasional refactoring That's exactly what I use the feature for.
In a refactoring IDE, you never risk overmatching or under-scoping. You just rename the syntactic object and it's renamed exactly where it needs to be, including possibly on the filesystem and in git.
The nice thing about replacing via vim is that you can restrict it to a selected block which also gives you a type of safety.
Particularly for the situation I used replacement today, an IDE couldn't make it better and doing it only on a range was helpful.
Re: Why Vi Rocks
#48Vim is like Dvorak. The cognitive burden for remembering which key maps to what is high unless you use it 24/7.
I have a friend who used to use Vi(m) with his Dvorak keyboard at home, and Emacs with his qwerty keyboard at work. He considered it an exercise for keeping his brain sharp. I don't think he still does it, but maybe. Vim on Dvorak is insane, imho.
Re: Why Vi Rocks
#49I’ve learned some vi, and emacs, Visual Studio, VS Code, XCode, IntelliJ, and Android Studio. All the examples listed are pretty uncommon or trivial in any of the other IDEs (aside from the regex part, which is cool, but I never want to be in a place where I have to regex my code...ever). 90% of the time I’m doing simple code maintenance, with an occasional refactoring. And I know devs that swear by vi...they are dev…
> And I know devs that swear by vi...they are developing any faster than I am I hear about this from time to time, but have never seen it people do it successfully first hand, what I do see is silly mistakes in their checkins; incomplete variable renames, formatting is off, syntax errors, switching between browsers and their code while looking at manuals, or other obvious mistakes that can be caught inline by IDEs wh…
edit/ A word.
Re: Why Vi Rocks
#50I’ve learned some vi, and emacs, Visual Studio, VS Code, XCode, IntelliJ, and Android Studio. All the examples listed are pretty uncommon or trivial in any of the other IDEs (aside from the regex part, which is cool, but I never want to be in a place where I have to regex my code...ever). 90% of the time I’m doing simple code maintenance, with an occasional refactoring. And I know devs that swear by vi...they are dev…
I am writing this from emacs experience (some if not all these features are in vi as well), there are features from emacs that make a real difference in writing programs especially: * Unlimited yanking from kill rings: ie pasting text from history of the clipboard.(This is one thing I have most difficulty with when switching from emacs to modern editors) * Macro recording and playback : recording an arbitrary set of…
I'm not sure exactly which vim features are also in vi. Vim has been a daily use tool for me since about 2007.
Vim has really good Macro recording. Vim + Tmux is great for side by side code frames, and there are plugins for showing multiple buffers in one Vim instance. Remote file editing is good with SSH + Vim. Vim has multiple registries for yanking/putting. Vim has column editing functionality.
Almost anything Emacs does out of the box Vim can do with either a plugin or with an external program pairing. I prefer Vim's keybindings because there are less "chords" (Ctrl-C and Ctrl-V are copy and paste chords, they requiring pressing two buttons at the same time). Too many chords causing my pinky fingers to become tired. Vimscript is a surprisingly powerful language for dealing with text data, but it's cryptic the first decade you are exposed to it.
EDIT: I'm more interesting in the code people write than the way people write it, but I wanted to share some of my vim knowledge and point of view.