Comment by worksonmine

2 days ago

> 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.