Comment by kace91
1 day ago
I do get the benefit of not depending on plugins, really. Long term my current config could rot (abandoned projects, moving dependencies, etc), while a simple config is stable. But I'm happy removing dependencies one at a time.
For example, <leader> ft toggles a terminal in a bottom split. This is familiar enough that I knew I could rely on it whenever needed.
Could I have used :term and manually set splits each time? or learn tmux? or use ctrl+z and fg to move back and forth ? Sure, but that's extra cognitive load.
Maybe I want to focus first on becoming fluid with regex for search and replace, or improving the flow for running unit tests, or get used to using macros as a replacement for multicursor. There's a lot of gaps to cover, each small enough that it's "just do X" for a veteran, but enough when added up that I would much rather pay the cost gradually.
> Could I have used :term and manually set splits each time?
That's when you know you want to create a keybinding, here's a suggestion that opens a split below the current window with 10% height and starts a terminal: `nnoremap <leader>ft :belowright 10 split | terminal<CR>`
But is a terminal really what you want or do you just want to run a command? Maybe just `:!command` is enough 9/10 times that you reach for <leader>ft? In that case a common binding is `nnoremap ! :!` which puts you in that mode with a single key.
> get used to using macros as a replacement for multicursor
This exact example was how I realized the vim way is better than my assumptions. I used to install a multicursor plugin and bind to Ctrl+d because that's what I knew. When I learned macros and s/old/new it became irrelevant.
You seem to already know a lot of the possibilities that you can learn, I didn't and discoverability in vim isn't great. So I just forced myself to search for whatever I didn't know how to achieve and many times ended up learning something extremely powerful.
Today I have all sorts of useful little functions, <leader>m is make, or gcc if no Makefile exists. And now I've extended it to generate mermaid charts in markdown files and open them in my imageviewer and so on.
That's the true power of vim to me, adding standard tools from the system in keybindings and just getting it to do things MY WAY, not how I was taught it should work. It follows the unix philosophy and batteries included is by definition not part of that mentality.
Same with Emacs. Needs some feature? Just write something quick in Elisp and have a new command. The primitives are versatile and a lot of tasks can be reduced to a few commands instead of a long interaction with the terminal/GUI.