mirror of
https://github.com/l0ng-ai/openidea.git
synced 2026-11-24 16:04:21 +00:00
The legacy shell stream mode works from fixed word lists: local, declare and return were plain text, and so were function definitions and any command outside its ~70 builtins. The bundled tree-sitter-bash grammar now draws its highlights over the stream mode, as Kotlin's does: declaration keywords, function definition names, command names and variables. Command names get their own colour (--syn-shell-command, Color Scheme › Shell Script › Command), blue in light and orange in dark schemes, falling back to the function-call colour in colour themes.
Outline queries (<grammar>/outline.scm), consumed by src/syntax/outline.rs.
Captures: @def.<kind> (outline + symbol index), @outline.<kind> (outline only),
@name (identifier; several are joined with .), @detail, @trait (Rust impls),
@container (explicit container, e.g. Go receivers). Captures starting with _ are ignored.
Kinds: class interface struct enum enum_member trait function method constructor
field property variable constant module namespace package type macro event operator
key heading impl extension. A function directly inside a type becomes a method.
When several patterns capture the same node, the earliest pattern wins.