indents.scm

 1(function_definition
 2  ":" @start
 3  body: (block) @indent
 4)
 5
 6(if_statement
 7  ":" @start
 8  consequence: (block) @indent
 9  alternative: (_)? @outdent
10)
11
12(else_clause
13  ":" @start
14  body: (block) @indent
15)
16
17(elif_clause
18  ":" @start
19  consequence: (block) @indent
20)
21
22(for_statement
23  ":" @start
24  body: (block) @indent
25)
26
27(with_statement
28  ":" @start
29  body: (block) @indent
30)
31
32(while_statement
33  ":" @start
34  body: (block) @indent
35)
36
37(match_statement
38  ":" @start
39  body: (block) @indent
40)
41
42(class_definition
43  ":" @start
44  body: (block) @indent
45)
46
47(case_clause
48  ":" @start
49  consequence: (block) @indent
50)
51
52(try_statement
53  ":" @start
54  body: (block) @indent
55  (except_clause)? @outdent
56  (else_clause)? @outdent
57  (finally_clause)? @outdent
58)
59
60(except_clause
61  ":" @start
62  (block) @indent
63)
64
65(finally_clause
66  ":" @start
67  (block) @indent
68)