Sadly, even though this looks amazing, I don't see myself using it until most of the plugins I use for Vim have been ported over. Does anyone here use Kakoune as their daily driver? Do you feel it's worth the switch from Vim?
Sadly, even though this looks amazing, I don't see myself using it until most of the plugins I use for Vim have been ported over. Does anyone here use Kakoune as their daily driver? Do you feel it's worth the switch from Vim?
I still use vi / vim for some of the usual suspects. I haven't bothered to change my $EDITOR, so I always default into vi unless I explicitly invoke kak. (Like right now, w3m invoked vi for me to write this comment.) And then there's visudo, which is far too much of a pain to set up for using kak. And kak doesn't to my knowledge have anything like vimdiff. Also, it doesn't work as well for what I call "interactive sed," where you do a global regex replacement. For ordinary source code editing though, I'm not going back. Selection-oriented editing with multiple cursors is just too much fun.
- Type `:%s/`
- Spend 30 seconds thinking up a regex which will hopefully match all the things I want to change, and none of the things I don't
- Write it out, hit Enter
- Run my tests, or run "git diff", or generally review the changes, and find a bunch of stuff is broken
- undo, restart from scratch
You can sometimes avoid screwing up the entire file with the "c" flag that asks for confirmation for each change, but it's too easy to get bored and distracted and type "y" too many times.
In Kakoune, a global regex replacement goes like:
- Type `%s`
- Spend five seconds thinking up a regex that approximately matches the things I want to change
- Interactively do any additional adjustments that are difficult to express in regex, like the `M` command that extends the selection to the next matching bracket
- Cycle through matches with `(` and `)`, checking to see if they're what I expected
- If not, I can remove individual selections with Alt-Space, or just hit %s and adjust my regex
- Type `c` and actually make the change
Because of the whole "multiple cursors" thing, I can get fast feedback on each part of the process, so I can get the result I want much more quickly.
- :set hlsearch
- Type `/`
- Spend five seconds thinking up a regex that approximately matches the things I want to change
- Hit Enter
- Cycle through matches with `n`/`N`, checking to see if they're what I expected
- If they're not, press `/` then <Up> and edit the regex
- When satisfied, type `:%s//`, enter the replacement you want to make, then `/g<Enter>` to apply the change everywhere
The "c" modifier makes you confirm each replacement, and you can y/n for each of them.
The only thing stopping me was my inability to configure it to use different indentation settings per file type.
I'll definitely try again at some point. I love Vim and have used it for nearly twenty years, but Kakoune's grammar just makes more sense in several ways.
Do you mind listing plugins you miss? That's probably depends on use-case but my impression is most of essential stuff is already available.