hou32hou
hou32hou on Hacker News
Have you actually tried it?
Have you used `*` to pick the keyboard layout?
In Ki you don't have to know the name of the syntax node, you can just press `d m`, and the editor will show the labels of all the syntax node visible that you can jump to.
"Emacs is an editor" is as true as "Toyota Hilux is a gattling gun carrier"
TBH, it's actually not as hard as you think, most of the time, what I do is just select the whole syntax node and delete it, copy it, or replace it, and only 20% of the time would actually require deliberate understanding of how the AST is structured in the current language I'm coding in.
Sorry for derailing a bit, the search and replace using a query make sense for purly textual (non-syntactic) editing, but if you want to apply consistent syntactic modifications across multiple locations in the same file, you will need both multi-cursor and syntax node selection/navigation/modification.
It's hard to explain unless you actually try Ki, because it is a paradigm shift
> It shows the creator comes from VSCode
Hey, one of the creators here, I actually daily drove Neovim for two years, before switching to Helix for a while, then finally Ki.
> multi-cursor is a useless feature
I was a Neovim macro user until I figured out how insane that was compared to multi-cursor after using Helix.
It's good at least in my case because I switch between Dvorak (Corne) and Qwerty (laptop's keyboard) all the time, without positional keymap, I would have to develop two sets of muscle memory
It's not generated by LLM, it was actually my idea, but grammar-corrected by LLM, but you are not wrong either, the docs are really subpar in a lot of ways, and not clearly explaining why is one of them, and of course, the potentially cringey sentences too, someone complained the docs read like a Vogue magazine before lol
> How does the machine I ssh to know my keyboard layout
Why does it need to? If you are using say, Dvorak, you can just pick the keyboard layout by pressing `*` (a keybinding which is not affected by the chosen keyboard layout)
Honestly they're just a bunch of data transformers plugged together to create the illusion of behaving like a human.
Do you mind sharing the Emacs package that does "tree based selection expanding" so I can better highlight their differences?
Multi-cursor, yes; structural selection, not so much, they are more like an afterthought for most editors, there’s a big difference between being treated as first-class and second-class.
Thank you for trying!
For character-based movement, simply press 'z' to enter the column mode.
Regarding the built-in tutor, yes I really have to put in the effort, because it's so much harder than authoring documentation.
And yes, a lot more has to be improved, Ki needs a lot of polishing around the edges.
I think it's significantly better, because you don't need to know the specific type of node you want to select.
In Ki, you only need to use `s` for any syntax node, while in nvim-treesitter-textobject, you need to use `vaf` for functions, `vac` for classes, and so on. Additionally, this also depends on how well the Tree-sitter queries are written, or if they're written at all.
Selection modes are sticky, so it would be “w l l l l l”
Künstliche Intelligenz. Sounds super cool, not gonna lie.
That's true for some users certainly, but I guess most users will not know which 4 easy-to-access keybindings to downgrade in exchange for the 4 syntax navigation keys, if it were you which 4 default keybindings are you willing to sacrifice?
The 4 movements are parent, first child, previous sibling, and next sibling.
To be frank it takes time to get used to, especially if you are already a Vim amateur.
However, once you get the hang of it you will find that most common operations can be achieved within 3 keypresses.
For example, to delete the current line, press `e` (Line selection mode) and then `d` (Delete).
To delete the current word, press `w` (Word selection mode) and then `d`.
To insert new text at the end of the current line, press `e`, then `a` (enter insert mode at the end of the selection).
To insert new text at the beginning of the current line, press `e`, then `i` (enter insert mode at the beginning of selection).
To go to the first line, press `e`, then `,` (Move to the first selection).
To go to the last line, press `e`, then `.` (Move to the last selection).
There are too many of such examples that I cannot fit in one comment, but I think you get the idea. It's all about creative combinations between selection modes and movements.
Ki is much inspired by Helix and Kakoune, however, it introduces an extra layer called the Selection Mode, with this, every movement is standardized to the same set of keybindings.
Also, most importantly, syntactical selection/navigation/modification is first class, although it is somehow supported in Helix, the default keybindings are not very accessible.
Another big difference from Helix is its internal architecture, most Helix components were rebuilt from scratch, while in Ki every components uses the core editor as the base, which means all components shares the same set of keybindings, you don't need to learn different set of keybindings for different components.
I will need help unfortunately because I don't have an accessible Windows machine.
For the configuration I'm planning something crazier, I might use my programming language that I built earlier (https://github.com/wongjiahau/kk).
Just `s` if your cursor is already placed on the first token of the function call node.
Posted by
hou32hou on Sunday September 08, 2024 @08:39PM
from the show-hn dept.
https://ki-editor.github.io/ki-editor/
Hi everyone, I have been developing this editor, Ki, for over a year, and have employed it substantially in all kinds of development (including Ki itself) for at least 3 months.I think it is mostly crystallized, thus I'm happy to share it with you today.Its main strength is first-class multi-cursor and structural (syntax) editing, which is a rare combination in the realm of editors (TUI or GUI...
Nope because I’m not convinced by this language anymore
It won’t be delivered because it’s actually my final year project for my software engineering degree, and plus I’m also not convinced by this language anymore, I still think that there’s a better syntax which I can’t think of right now
No no we haven’t broke up yet
Yea it is indeed halted, because I’m still in search of a better syntax.