mirror of
https://github.com/nvim-treesitter/nvim-treesitter.git
synced 2026-07-01 19:17:02 -04:00
folds support and somewhat better indents for ruby
This commit is contained in:
parent
065ff440d4
commit
11ede1c0d2
2 changed files with 26 additions and 0 deletions
12
queries/ruby/folds.scm
Normal file
12
queries/ruby/folds.scm
Normal file
|
|
@ -0,0 +1,12 @@
|
|||
[
|
||||
(method)
|
||||
(singleton_method)
|
||||
(class)
|
||||
(module)
|
||||
(if)
|
||||
(else)
|
||||
(case)
|
||||
(do_block)
|
||||
(singleton_class)
|
||||
(lambda)
|
||||
] @fold
|
||||
|
|
@ -1,12 +1,26 @@
|
|||
[
|
||||
(class)
|
||||
(method)
|
||||
(singleton_method)
|
||||
(module)
|
||||
(call)
|
||||
(if)
|
||||
(block)
|
||||
(do_block)
|
||||
(hash)
|
||||
(array)
|
||||
(argument_list)
|
||||
(case)
|
||||
] @indent
|
||||
|
||||
[
|
||||
"("
|
||||
")"
|
||||
"{"
|
||||
"}"
|
||||
"["
|
||||
"]"
|
||||
(when)
|
||||
(elsif)
|
||||
"end"
|
||||
] @branch
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue