feat(cmake): update cmake parser, adapt highlight.scm, and add indents.scm

This commit is contained in:
Uy Ha 2023-06-28 15:19:58 +00:00 committed by Christian Clason
parent f04f137acb
commit e68ad094cd
3 changed files with 93 additions and 44 deletions

21
queries/cmake/indents.scm Normal file
View file

@ -0,0 +1,21 @@
[
(normal_command)
(if_condition)
(foreach_loop)
(while_loop)
(function_def)
(macro_def)
(block_def)
] @indent.begin
[
(elseif_command)
(elseif_command)
(endif_command)
(endforeach_command)
(endfunction_command)
(endmacro_command)
(endblock_command)
] @indent.branch
(normal_command ")" @indent.branch)