mirror of
https://github.com/helix-editor/helix
synced 2026-08-05 14:42:57 +02:00
* feat(languages): add Concerto modelling language support Add tree-sitter grammar and queries for the Concerto Modelling Language (.cto files) by the Accord Project. Concerto is a schema language for defining data models used in smart legal contracts and business networks. Language features: - 8 declaration types: concept, asset, participant, transaction, event, enum, scalar, map - 6 primitive types: String, Boolean, DateTime, Integer, Long, Double - Decorators, validators, relationships, imports with versioning Queries included: - highlights.scm — full syntax highlighting - textobjects.scm — class (type), comment, and parameter text objects - indents.scm — auto-indentation for declaration bodies - locals.scm — scope, definition, and reference tracking Grammar source: https://github.com/accordproject/concerto-tree-sitter Language spec: https://concerto.accordproject.org
22 lines
547 B
Scheme
22 lines
547 B
Scheme
; Concerto Language - Indent Queries (Helix)
|
|
; ============================================
|
|
; Helix-specific indentation rules. For use in helix-editor/helix at
|
|
; runtime/queries/concerto/indents.scm
|
|
;
|
|
; Helix uses @indent and @outdent captures, same as tree-sitter convention.
|
|
; See: https://docs.helix-editor.com/guides/indent.html
|
|
|
|
; Indent inside declaration bodies and decorator argument lists
|
|
[
|
|
(class_body)
|
|
(enum_body)
|
|
(map_body)
|
|
(decorator_arguments)
|
|
] @indent
|
|
|
|
; Outdent at closing braces and parentheses
|
|
[
|
|
"}"
|
|
")"
|
|
] @outdent
|