#tree-sitter #kakoune

app kak-tree-sitter

Server between Kakoune and tree-sitter

5 releases (3 breaking)

new 0.3.0 Jun 8, 2023
0.2.0 May 24, 2023
0.1.8 Apr 30, 2023
0.1.7 Apr 30, 2023
0.0.0 Apr 27, 2023

#37 in Text editors

Download history 56/week @ 2023-04-25 14/week @ 2023-05-02 13/week @ 2023-05-09 3/week @ 2023-05-16 32/week @ 2023-05-23 8/week @ 2023-05-30

56 downloads per month

BSD-3-Clause

46KB
1K SLoC

Rust 1K SLoC // 0.0% comments Kakoune script 120 SLoC // 0.2% comments

kak-tree-sitter

This is a binary server that interfaces tree-sitter with kakoune.

Features

  • Semantic highlighting.
  • Semantic selections (types, functions, declarations, etc.)
  • Efficient parsing via tree-sitter, with partial parsing, etc.
  • Shared between Kakoune sessions.

Install

Currently, the only installation channel, which is not ideal, is via cargo:

cargo install kak-tree-sitter

Optionally, you can install the CLI controller:

cargo install ktsctl

Usage

See the wiki.

Design

Alternatives

  • tree-sitter.kak: a similar project, with the same motivations. It’s currently the only viable alternative with both features (semantic highlighting / selections).

Credits

This program was heavily inspired by kak-tree, by @ul.

Dependencies

~6–12MB
~221K SLoC