diff options
| author | John Isom <John.Isom2001@gmail.com> | 2020-07-27 12:15:11 -0600 |
|---|---|---|
| committer | John Isom <John.Isom2001@gmail.com> | 2020-07-27 12:15:11 -0600 |
| commit | de214d262c2dff13974e4905fbb6a2dc89526736 (patch) | |
| tree | bfcfb4d35de95d621733522862d58c9843921eb9 | |
| parent | 26f4681c3bc7462184accb06d78c4d5ea9082e3a (diff) | |
Update rust brace deindenting to handle bad indentation edge case
| -rw-r--r-- | rc/filetype/rust.kak | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/rc/filetype/rust.kak b/rc/filetype/rust.kak index 4b393213..a5f05da2 100644 --- a/rc/filetype/rust.kak +++ b/rc/filetype/rust.kak @@ -113,7 +113,7 @@ define-command -hidden rust-indent-on-new-line %~ # dedent after lines starting with . and ending with , or ; try %_ execute-keys -draft k <a-x> <a-k> ^\h*\..*[,<semicolon>]\h*$ <ret> j <a-lt> _ # deindent closing brace(s) when after cursor - try %< execute-keys -draft <a-x> <a-k>^\h*[})]+\h*$<ret> <a-lt> > + try %< execute-keys -draft <a-x> <a-k>^\h*[})]+\h*$<ret> hm <a-S> 1<a-&> > # todo dedent additional unmatched parenthesis # try %& execute-keys -draft k <a-x> s \((?:[^)(]+|\((?:[^)(]+|\([^)(]*\))*\))*\) l Gl s\) %sh{ # count previous selections length |
