11 ms·
Kakoune – An experiment for a better code editor
- pkkp 11y agoYou'll want to take a look at your site's theme on mobile devices. On my iPhone 6 on iOS 9 (Safari), the navigation bar is fixed at the top half of the pane and takes up over half the screen.
- voltagex_ 11y agoIt looks like the site's built with GitHub Pages so you could raise an issue for it: https://github.com/mawww/kakoune/issues https://github.com/mawww/kakoune/issues
- mintplant 11y agoWhy downvote this? The submitter here isn't necessarily the author, so the author is more likely to see this if someone submits an issue for it.
- vinceguidry 11y agoA lot of downvotes happen by accident, as on mobile it's easy to fat-finger the down arrow. No need to comment, typically people will notice the mistake and correct it with upvotes. If the mods read this, I'd like to put in a suggestion to, on mobile, add CSS that places the down arrow on the right side of the screen, nowhere near the up arrow on the left, and make the icons bigger so you can tap them without having to zoom in. Or if that looks cluttered, make the icons as big as they normally are, but make the clickable space larger using padding rules. This is the biggest UX problem HN has, in my opinion.
- delish 11y agoSame here. Here's a picture. https://twitter.com/zlrth/status/660671388693323777 https://twitter.com/zlrth/status/660671388693323777 iPhone 5s, iOS 9.1. sorry to all reading my tweet about the snark. But I just find it so sad that I have so much rendering power on desktop (JavaScript on/off, elinks web browser, my rss reader), but if some silly CSS thing borks the mobile page, there's nothing I can do.
- RadioactiveMan 11y agoI came here to include a picture of the kakoune.org problem, but since you already have one I'll include a (hilariously?) similar picture of your tweet. http://i.imgur.com/zUYt7V9.jpg http://i.imgur.com/zUYt7V9.jpg On the subject of kak, I tried it a few months ago and thought it was really impressed by it but didn't stick with it long enough to decide if it would be better than vim for me.
- cpfohl 11y agoI can't even say how happy it made me that Clippy made it into a CLI program. Is that a common joke I've just missed elsewhere?
- chc4 11y agoI've played with Kakoune a little bit not that long ago. It's actually pretty nice. By far the best feature is the popup that lists all the sub-actions for chords: imagine if, when you press "g" in Vim, it lists all keys you press after AND what they do. It makes it very easy to figure out new behavior. The idea of working on selections is also very intuitive and works well, both in vim compatability and ease of use. The biggest issue I had with it, that made me return to Vim instead of try and keep with Kakoune, are the lack of options. A lot of the settings appear to be hardcoded, with no way to set them even with : commands. While it does have scripting support, and a lot of the core application is implemented with it, there doesn't seem to be any docs on how it works or any community behind it.
- syl20bnr 11y agoAuto-promotion here :-D Check Spacemacs, it is an Emacs configuration usable by Vim users out of the box. It has the feature you mentioned powered by the which-key package.
- Naomarik 11y agoI'm a spacemacs convert after using vim for 2 years. This editor + configuration is extremely hard to beat. I just pulled from master after using it full time for two months and updates were amazing. Way better ergonomics than vim and elisp is extremely easy to hack on.
- dm3 11y agoAs a counterpoint - I went back to VIM after a month of spacemacs. I've actually put in the effort to learn the keybindings for all the relevant tasks I needed and the way Emacs works internally, as much as it's possible in a month. I was doing Clojure and the main problem for me was the less fluent editing - most commands in vim are at least one keystroke shorter. The other big problem are non-evilified plugins that completely mess up the workflow - you constantly keep switching between "I'm in VIM" and "I'm in Emacs" mindset. Also, emacs feels a bit more sluggish, although that may be just CIDER. The things I loved: * helm mode - autocompletions for the commands * consistency - SPC + ... everywhere * REPL in a buffer I understand that a month with Emacs isn't remotely enough to make up for years of VIM, but I didn't find enough benefits to stick with it.
- Direct 11y agoI tried switching to this editor permanently from vim. The selection based movements are asurdly good, I could kill for something like this in vim. However I couldn't stick with it for two reasons. The first is when I went to figure out how to customise it, I found that the customisation is essentially vim like but weaker. Everything is hardcoded like it would be in vim but with less options. If you're used to Emacs insane customization, this is the other end of the spectrum. The stuff that IS customisable works by executing embedded bash scripts[1]!? You can only embed these in specific hooks and places, so it's really limited, and platform specific. Install this on a system missing a bash feature someone is using and who knows how it'll behave. Basically, the features implemented are gorgeous, but past that I can't stick with it. Just going to consider trying to port the selection based movements to a vim plugin but I think it'll be a challenge. 1: https://github.com/mawww/kakoune/blob/master/rc/clang.kak https://github.com/mawww/kakoune/blob/master/rc/clang.kak
- i336_ 11y agoI'm guessing it wouldn't be too difficult to clone the motion system et. al. in emacs?
- mawww 11y agoHello, Glad to hear you liked the interaction model, may I ask you what kind of options were missing for you ? The extension model is, I agree, unorthodox, but I think it does work reasonably well (the file you linked manage to provide asynchrounous clang completion and syntastic like diagnostics using it), and keeps things simple. Note that we try really hard only to depends on POSIX tools, so the scripts are actually targeting POSIX shell. The rational behind this extension model can be found there: https://github.com/mawww/kakoune/blob/master/doc/design.asciidoc https://github.com/mawww/kakoune/blob/master/doc/design.asci... And a more in depth explanation on how to use it is there: https://github.com/mawww/kakoune/blob/master/doc/interfacing.asciidoc https://github.com/mawww/kakoune/blob/master/doc/interfacing...
- Direct 11y agoHonestly it's been a little while, I can't remember. However this is more or less why I went back to vim. Your other comment in particular: > We do not have options for everything, but I'll gladly add more options if there is a reasonable use case for them. In other words, options only get added if someone requests them (and makes a good case for them). I don't really want to switch to an editor where missing options might have to be justified. I'm not knocking your work, it's really good, and my complaint applies to vim as well. But if I can't implement something myself as an add-on (which I definitely have more power to do in vim) and have to wait for it to be patched and released in your release cycle I'd rather just try and implement your features in vim and keep the customisability. Having said that I could be wrong and maybe the plugin system is more powerful than I thought. But as an example, I have a 5 line function letting me have ctrl-p like functionality backed by fzf in vim. I can't figure out how I would do that in kakoune at all.
- eccstartup 11y agoDocumentation in PDF available?
- openfuture 11y agoI'm hoping neovim will be able to adapt these ideas in the future. They're addressing all the hardcoded parts so it should be possible to make any of these with an addon / some nvimrc magic.
- deleted 11y ago[deleted]
- mercurial 11y agoIt looks nice, and I assume the underlying code is less gnarly than vim's, but I don't see the radical improvement over vim which would make me switch (also, obviously, it's not going to benefit from the huge ecosystem of vim plugins). What I think would be a killer for a vim successor would be to keep the best-in-class editor functionality, add decent extensibility (not vimscript) in the core product. Then add support for stuff commonly found in IDEs: notion of projects/subprojects, API to support plugging syntax parsers easily, source control integration, etc., and offer core plugins for a few popular languages.
- h2077545 11y agoKakoune seems great and I hope I will eventually make the switch from vim but there are currently 3 things holding me back. 1. Slime-like interaction: In vim I'm used to [vim-slime](https://github.com/jpalardy/vim-slime https://github.com/jpalardy/vim-slime) for interactive languages such as python but I couldn't yet find an equivalent way to do it in kakoune. I suspect there is an easy way to do something like this using `:new` or the tmux integration but I don't know how. 2. Executing commands in the underlying shell: With C/C++ I usually need to work only with a single file and a fast compile-run cycle. I have simple functions defined for compile and run in my vimrc so that I can do it with a simple key map but I'm not sure how to do this in kakoune. The problem is sometimes output of my program exceeds one line so `:echo` is not quite useful here. 3. ctags/cscope integration: I haven't really checked this yet but I need something for jumping around in large codebases.
- mawww 11y agoHello, 1. that is missing, but mostly because nobody needed it yet, and I am not very familiar with repl style languages. I expect it to be implementable with current features. 2. The simplest way to do that is to set the makecmd option, options can be set per buffer, so each C++ buffer can have it set to the compile command for it. You'll get output in the make buffer. 3. I use ctags a lot, and it is well supported, it requires the readtags command that is provided by default in universal-ctags, and needs to be installed manually with the older exuberant ctags. There is no cscope support script AFAIK (although should be possible).
- quanticle 11y agoOne piece of feedback about the website itself: the actual reading area is unusably small when viewed on a mobile device. Here's a screenshot:http://imgur.com/yvOGc02 http://imgur.com/yvOGc02. Note that the menu doesn't hide, so >50% of the screen is occupied by a static menu that's irrelevant to the actual content I'm trying to read.
- GhotiFish 11y agoFirst impressions with this editor are very good. One thing I'm not 100% sure how to do is substituions with references so if I want to change the all the strings "foo(5, bar)" to "baz(bar).foo(5)" with 5 and bar being arbitrary strings. How could I do that? In vim I would use a regex expression and refer to matching sections with "%s/foo(\([^,]+\), \([^)]+\))/baz(\2).foo(\1)/gc". In Kakoune it seems I might have to do some multiselect shenanigans, the regex has better escaping for my taste, but I can't match on specific selections. So I can't shuffle them arbitrarily. I looked through the vim golf challenges and couldn't find Kakoune doing an operation like this. mawww, do you have some screencasts of you using this editor? I would be nice to have some live demonstrations showing off useful and common usage patterns for it.
- mawww 11y agoHello, If you get your selections through a regex, you will have access to capture groups in registers 0..9 (which will store the correct match for each selections), so to do the change you wanted, you'll type (in normal mode, no ':'): %sfoo\(([^,]+), ([^)]+)\)<ret> # select whole buffer, then select all regex matches cbaz(<c-r>2).foo(<c-r>1)<esc> # enter insert mode, <c-r> recalls a register I have been meaning to do a screencast at some point, or maybe I could do a twitch Q/A session.