summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJohn Isom <John.Isom2001@gmail.com>2020-08-01 12:12:48 -0600
committerJohn Isom <John.Isom2001@gmail.com>2020-08-01 12:12:48 -0600
commite858df3ca288ce816068b2d163b7bbcbfdab90f8 (patch)
tree54ff4036addd17a6532e6d0aabd119cdc49d0044
parentdbb548af2dce84dc557e81f1d7cd1c2951071ce4 (diff)
Add 'else' to auto deindent/align logic in context of 'case' statement
-rw-r--r--rc/filetype/crystal.kak4
1 files changed, 2 insertions, 2 deletions
diff --git a/rc/filetype/crystal.kak b/rc/filetype/crystal.kak
index 1a55ffde..74c283d8 100644
--- a/rc/filetype/crystal.kak
+++ b/rc/filetype/crystal.kak
@@ -190,8 +190,8 @@ define-command -hidden crystal-indent-on-char %{
evaluate-commands -no-hooks -draft -itersel %{
# align 'else/elsif' to 'if'
try %{ execute-keys -draft <a-x> <a-k> ^\h*(?:else|elsif)$ <ret> <a-a>i <a-semicolon> <a-?> ^\h*(?:if) <ret> <a-S> 1<a-&> }
- # align 'when' to 'case'
- try %{ execute-keys -draft <a-x> <a-k> ^\h*(?:when)$ <ret> <a-a>i <a-semicolon> <a-?> ^\h*(?:case) <ret> <a-S> 1<a-&> }
+ # align 'else/when' to 'case'
+ try %{ execute-keys -draft <a-x> <a-k> ^\h*(?:else|when)$ <ret> <a-a>i <a-semicolon> <a-?> ^\h*(?:case) <ret> <a-S> 1<a-&> }
# align 'rescue' to 'begin/def'
try %{ execute-keys -draft <a-x> <a-k> ^\h*(?:rescue)$ <ret> <a-a>i <a-semicolon> <a-?> ^\h*(?:begin|def) <ret> <a-S> 1<a-&> }
# align 'end' to opening structure