Merge remote-tracking branch 'eraserhd/clojure-fix-for-1-char-symbols'

This commit is contained in:
Maxime Coste 2019-05-21 21:36:30 +10:00
commit 6b7f445936

View File

@ -199,11 +199,11 @@ define-command -hidden clojure-indent-on-new-line %{
try %{
# If a special form, indent another (indentwidth - 1) spaces
execute-keys -draft '"wze<a-k>\A' %opt{clojure_special_indent_forms} '\z<ret>'
execute-keys -draft '"wze<a-K>[\s()\[\]\{\}]<ret><a-k>\A' %opt{clojure_special_indent_forms} '\z<ret>'
execute-keys -draft '"wze<a-L>s.{' %sh{printf $(( kak_opt_indentwidth - 1 ))} '}\K.*<ret><a-;>;"i<a-Z><gt>'
} catch %{
# If not special and parameter appears on line 1, indent to parameter
execute-keys -draft '"wze<a-l>s\h\K[^\s].*<ret><a-;>;"i<a-Z><gt>'
execute-keys -draft '"wze<a-K>[\s()\[\]\{\}]<ret><a-l>s\h\K[^\s].*<ret><a-;>;"i<a-Z><gt>'
}
}
try %{ execute-keys -draft '[rl"i<a-Z><gt>' }