5 ms·
I really regret every trying Kakoune. It was totally not worth it, but I just can't go back now. I've switched from Vim to Kakoune 3 years ago, and lack of sup
by dpc_pw 6y ago
I really regret every trying Kakoune. It was totally not worth it, but I just can't go back now.
I've switched from Vim to Kakoune 3 years ago, and lack of support for this modal editing style elsewhere is really frustrating. It is better than Vim's, but in practice that's not a significant difference, and the pain of switching back and forth is something I'm agonizing over all the time.
BTW. The exact kakoune modal editing mode is not even all that flawless. The way x and X work on empty lines is infuriating, and I am actually using a personal fork of kakoune to fix it. https://github.com/dpc/kakoune-dpc https://github.com/dpc/kakoune-dpc . I went so far as prototyping a spinoff of Kakoune: https://github.com/dpc/breeze https://github.com/dpc/breeze to look for improvement, but building a full-featured text editor is a lot of work, and I it's not like it's going to fix the problem of switching.
- tux1968 6y agoWould you say a few words on what makes Kakoune modal editing better than Vim's?
- kakouneUserTmp 6y agoNot the same guy but I'm a convert from vim also. >Would you say a few words on what makes Kakoune modal editing better than Vim's? I guess the big difference is multiple selections. In Kakoune Normal mode you can select multiple selections, and your normal mode commands operate on all those selections at once, and if you switch to insert mode you can insert text at all of those multiple cursors. I had a paragraph with examples that I just deleted because it had sentences like "you would simply type s;<enter>b&" and that makes you sound like a crazy cultist. A better endorsement is maybe: where I would in the past write a script in python or awk to get info from a log or a csv I usually just jump straight to kakoune and edit the file down to the data I want.
- b0rsuk 6y agoAnd I consider multiple selections a flaw, a poor man's search&replace. Particularly with neovim's set inccommand=split (live substitution). Vim's confirmation prompts make it more comfortable, as well as off-screen matches it shows. Multiple selections are inherently limited to a single screen or you won't be able to see what you're doing. Verdict: a gimmick.
- otikik 6y agoWhen I tried `set inccommand=split` in neovim it would sometimes freeze the editor, even when substituting regular-sized files (several Kb), so I had to deactivate it. Granted that this was some time ago, so it might have been improved with recent versions. To me however multiple selections are not Kakoune's strongest point. It's the fact that in Kakoune you "first select, then modify", while in vim you go "action first, then subject". Putting the subject first allows for a more visual experience in general - in Kakoune you can always "see what's going to happen" before it happens, because the object is always highlighted. The multiple cursors thing is just a manifestation of this approach. In Vim the experience is more "opaque" - you type some commands in normal mode and suddenly the text changes. As a result Kak is less prone to "accidental edits" like I get in Vim from time to time. I've heard that some people "abuse" on Vim's Visual mode to get over this limitation. But that feels like a kludge to me. And it doesn't solve the accidental edits.
- deleted 6y ago[deleted]
- mawww 6y agoKakoune goes the opposite way, there is no such thing as "search and replace" in it, you'd use multiselection for that. It ends up being much more powerful because the editing language is strictly more expressive than regular expressions: you can select using a regular expression, but you can also use all the rest of the normal mode, such as select/jump to the matching parenthesis or brace (or whatever pair of text your language use to scope things), which is not possible to express in pure regex. You are far from limited to a single screen, the `(` and `)` commands rotate the main selection, so you can inspect all your selections easily if you want to. In my experience (as a long time Vim user and as Kakoune's main author) multiple selections end-up being much more attractive for quick edits where there's only a handful instances to replace than devising the correct regex/replacement pair, and their interactive nature makes them quicker to use than the macro alternative (which is also supported in Kakoune).
- sevensor 6y agoI'd just like to add that if you want to do regex-based search and replace like in Vim, it's super easy to pipe your selection through sed. The way Kakoune implements pipes is just amazingly good. I love that if you have multiple selections, each one gets piped through the command. I love that you can undo piping your selections to another program. And while I've barely scratched the surface of what you can do with macros, I have a couple that I use constantly. After 19 years with vi and then vim, I switched to kak after trying it for a week. In summary: great job with Kakoune! I'm a delighted user.
- tomsmeding 6y agoThere is a multiple cursors plugin for vim that I use; it's a bit clunky at times, but it does the job. How is kakoune's multiple cursors support better than that? How cool is it, so to speak? Btw the reason I haven't tried kakoune yet is that the command is `kak`, which means 'shit' in my native language, Dutch.
- kakouneUserTmp 6y ago>There is a multiple cursors plugin for vim that I use; it's a bit clunky at times, but it does the job. How is kakoune's multiple cursors support better than that? How cool is it, so to speak? I haven't used the vim plugin but if vim commands work on each selection that probably gets you half way. Kakoune additionally provides 's' and 'S' commands to sub select down from your selection iteratively. you might select all words, then select the _ in each word, delete the character and hit ~ to capitalize the next character to convert a selection of words in snake_case to camelCase. I think it's cool. >Btw the reason I haven't tried kakoune yet is that the command is `kak`, which means 'shit' in my native language, Dutch. I've actually heard this either on a forum, mailing list or a github issue at least once, lol. It's unfortunate.
- codetrotter 6y ago>> Btw the reason I haven't tried kakoune yet is that the command is `kak`, which means 'shit' in my native language, Dutch. > I've actually heard this either on a forum, mailing list or a github issue at least once, lol. It's unfortunate. I think if someone really wants to use Kakoune they could do the same thing that I do with neovim, which is to make vim be an alias for the editor you actually want to use.
- messo 6y agoSpeaking of unfortunate naming: 'bash' is pronounced exactly like the Norwegian word 'bæsj', which also means shit/poop. This has been the cause of some hilarious situations where non-technical people have overheard a nerdy conversation
- 6y ago
- xmprt 6y agoI think more than anything, you've convinced me that I'm probably never switching to Vim. I've really considered it because a lot of people I've worked with use it and claim it makes them much more productive, but I've been pretty productive in my IDE and I've been doing all those multiple selection and "scripting" type things in Sublime and IntelliJ for years.
- dpc_pw 6y agoBefore 3 yeas of kakoune, I did like 20 years of Vim. IMO, typing is less than 0.1% of SWE, so even if you can get 2x typing productivity with Vim it will still not amount to any substantial overall productivity benefit. If IDE works for you and you enjoy it, stick with it. I enjoy modal editing (Vim/kak) because it feels good. I don't have to move my hands from the home row and I'm a damn impatient person, so that fast editing just makes me feel a little better about "waiting for IO".
- boogies 6y ago> I guess the big difference is multiple selections. In Kakoune Normal mode you can select multiple selections, and your normal mode commands operate on all those selections at once, and if you switch to insert mode you can insert text at all of those multiple cursors. This is why I switched to vis (https://github.com/martanne/vis https://github.com/martanne/vis) after trying kak for a couple days (and previously being an nvim user). ^k and ^j add cursors directly above and below the current one, :x/foo/ selects all occurrences of ‘foo’ in the current selection or (if there’s no current selection) file (this is based on the command language of Rob Pike’s `sam` editor, and foo can be a structural regex), and then you can manipulate them using standard vi bindings.
- dpc_pw 6y agoEditing in Vim feels like a bit like editing in `ed` if you ever tried it. It's a bit like "type in a command, and see the result". You type d3w and you will get 3 word deleted. In Kakoune every keypress results in visual response. You type 3w, you see that 3 words were selected, then you hit d and they get deleted. It makes editing much more interactive, smooth and less error prone. Unlike the other responder, I am actually not big fan of multiple selections and prefer search and replace. But once in a while multiple selections come handy even for me, so I don't mind them being there.
- tasuki 6y agoYour comment will save me a lot of time. Thank you.