mirror of
https://github.com/mawww/kakoune.git
synced 2024-12-28 06:08:05 +03:00
Fix indentation rule for go.kak
This commit is contained in:
parent
194cb17aae
commit
902f2831d8
@ -89,6 +89,8 @@ define-command -hidden go-indent-on-new-line %~
|
||||
try %[ execute-keys -draft k<a-x> <a-k> ^\h*(case|default).*:$ <ret> j<a-gt> ]
|
||||
# indent after if|else|while|for
|
||||
try %[ execute-keys -draft <semicolon><a-F>)MB <a-k> \A(if|else|while|for)\h*\(.*\)\h*\n\h*\n?\z <ret> s \A|.\z <ret> 1<a-&>1<a-space><a-gt> ]
|
||||
# deindent closing brace(s)
|
||||
try %[ execute-keys -draft <a-x> <a-k>^\h*[})]+\h*$<ret> <a-lt> ]
|
||||
=
|
||||
~
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user