With the introduction of text-objects and a redesign of buffer streaming coming up, it’s time to refactor a bit. We could start by extracting every type in its own module, and classify modules in different parts:
server; everything that revolves around the concept of client/server (UNIX handler, FIFO management, etc.)
protocol; everything that revolves around the concept of encoding messages (requests, responses, basically)
tree_sitter; everything that revolves around actually doing something with buffers and tree-sitter. Buffers are parsed into tree-sitter trees, and we can highlight and run text-objects.
kakoune; everything that relates to Kakoune, like the kak -p thing; sessions; locations / pos / selections, etc.; ideally, we could almost even think of this module as a crate we could externalize and share with e.g. kakoune-lsp (@krobelus).
rc, the resources that we will inject at startup of a session; that is going to be useful later when we let users pick their features from this module.
With the introduction of text-objects and a redesign of buffer streaming coming up, it’s time to refactor a bit. We could start by extracting every type in its own module, and classify modules in different parts:
server
; everything that revolves around the concept of client/server (UNIX handler, FIFO management, etc.)protocol
; everything that revolves around the concept of encoding messages (requests, responses, basically)tree_sitter
; everything that revolves around actually doing something with buffers and tree-sitter. Buffers are parsed into tree-sitter trees, and we can highlight and run text-objects.kakoune
; everything that relates to Kakoune, like thekak -p
thing; sessions; locations / pos / selections, etc.; ideally, we could almost even think of this module as a crate we could externalize and share with e.g.kakoune-lsp
(@krobelus).rc
, the resources that we will inject at startup of a session; that is going to be useful later when we let users pick their features from this module.