mirror of
https://github.com/mawww/kakoune.git
synced 2024-11-24 16:15:38 +03:00
Merge remote-tracking branch 'Screwtapello/markdown-indent-fixes'
This commit is contained in:
commit
9858053d97
@ -127,7 +127,7 @@ add-highlighter -group /markdown/content regex \H\K\h\h$ 0:PrimarySelection
|
||||
def -hidden markdown-indent-on-new-line %{
|
||||
eval -draft -itersel %{
|
||||
# copy block quote(s), list item prefix and following white spaces
|
||||
try %{ exec -draft k <a-x> s ^\h*\K((>\h*)|[*+-])+\h* <ret> y gh j P }
|
||||
try %{ exec -draft k <a-x> s ^\h*\K((>\h*)+([*+-]\h)?|(>\h*)*[*+-]\h)\h* <ret> y gh j P }
|
||||
# preserve previous line indent
|
||||
try %{ exec -draft \; K <a-&> }
|
||||
# remove trailing white spaces
|
||||
|
1
test/indent/markdown/inside-complex-blockquote/cmd
Normal file
1
test/indent/markdown/inside-complex-blockquote/cmd
Normal file
@ -0,0 +1 @@
|
||||
i<ret><esc>
|
1
test/indent/markdown/inside-complex-blockquote/in
Normal file
1
test/indent/markdown/inside-complex-blockquote/in
Normal file
@ -0,0 +1 @@
|
||||
>> > > block %(q)uote
|
2
test/indent/markdown/inside-complex-blockquote/out
Normal file
2
test/indent/markdown/inside-complex-blockquote/out
Normal file
@ -0,0 +1,2 @@
|
||||
>> > > block
|
||||
>> > > quote
|
3
test/indent/markdown/inside-complex-blockquote/rc
Normal file
3
test/indent/markdown/inside-complex-blockquote/rc
Normal file
@ -0,0 +1,3 @@
|
||||
source "%val{runtime}/colors/default.kak"
|
||||
source "%val{runtime}/rc/base/markdown.kak"
|
||||
set buffer filetype markdown
|
1
test/indent/markdown/inside-nested-list-item/cmd
Normal file
1
test/indent/markdown/inside-nested-list-item/cmd
Normal file
@ -0,0 +1 @@
|
||||
a<ret><esc>
|
2
test/indent/markdown/inside-nested-list-item/in
Normal file
2
test/indent/markdown/inside-nested-list-item/in
Normal file
@ -0,0 +1,2 @@
|
||||
- parent
|
||||
* some%( )child
|
3
test/indent/markdown/inside-nested-list-item/out
Normal file
3
test/indent/markdown/inside-nested-list-item/out
Normal file
@ -0,0 +1,3 @@
|
||||
- parent
|
||||
* some
|
||||
* child
|
3
test/indent/markdown/inside-nested-list-item/rc
Normal file
3
test/indent/markdown/inside-nested-list-item/rc
Normal file
@ -0,0 +1,3 @@
|
||||
source "%val{runtime}/colors/default.kak"
|
||||
source "%val{runtime}/rc/base/markdown.kak"
|
||||
set buffer filetype markdown
|
1
test/indent/markdown/inside-simple-blockquote/cmd
Normal file
1
test/indent/markdown/inside-simple-blockquote/cmd
Normal file
@ -0,0 +1 @@
|
||||
i<ret><esc>
|
1
test/indent/markdown/inside-simple-blockquote/in
Normal file
1
test/indent/markdown/inside-simple-blockquote/in
Normal file
@ -0,0 +1 @@
|
||||
> block %(q)uote
|
2
test/indent/markdown/inside-simple-blockquote/out
Normal file
2
test/indent/markdown/inside-simple-blockquote/out
Normal file
@ -0,0 +1,2 @@
|
||||
> block
|
||||
> quote
|
3
test/indent/markdown/inside-simple-blockquote/rc
Normal file
3
test/indent/markdown/inside-simple-blockquote/rc
Normal file
@ -0,0 +1,3 @@
|
||||
source "%val{runtime}/colors/default.kak"
|
||||
source "%val{runtime}/rc/base/markdown.kak"
|
||||
set buffer filetype markdown
|
1
test/indent/markdown/inside-strong-emphasis/cmd
Normal file
1
test/indent/markdown/inside-strong-emphasis/cmd
Normal file
@ -0,0 +1 @@
|
||||
i<ret><esc>
|
1
test/indent/markdown/inside-strong-emphasis/in
Normal file
1
test/indent/markdown/inside-strong-emphasis/in
Normal file
@ -0,0 +1 @@
|
||||
**strong %(e)mphasis**
|
2
test/indent/markdown/inside-strong-emphasis/out
Normal file
2
test/indent/markdown/inside-strong-emphasis/out
Normal file
@ -0,0 +1,2 @@
|
||||
**strong
|
||||
emphasis**
|
3
test/indent/markdown/inside-strong-emphasis/rc
Normal file
3
test/indent/markdown/inside-strong-emphasis/rc
Normal file
@ -0,0 +1,3 @@
|
||||
source "%val{runtime}/colors/default.kak"
|
||||
source "%val{runtime}/rc/base/markdown.kak"
|
||||
set buffer filetype markdown
|
1
test/indent/markdown/open-after-setext-heading-1/cmd
Normal file
1
test/indent/markdown/open-after-setext-heading-1/cmd
Normal file
@ -0,0 +1 @@
|
||||
o
|
2
test/indent/markdown/open-after-setext-heading-1/in
Normal file
2
test/indent/markdown/open-after-setext-heading-1/in
Normal file
@ -0,0 +1,2 @@
|
||||
Some Heading
|
||||
%(=)===========
|
3
test/indent/markdown/open-after-setext-heading-1/out
Normal file
3
test/indent/markdown/open-after-setext-heading-1/out
Normal file
@ -0,0 +1,3 @@
|
||||
Some Heading
|
||||
============
|
||||
|
3
test/indent/markdown/open-after-setext-heading-1/rc
Normal file
3
test/indent/markdown/open-after-setext-heading-1/rc
Normal file
@ -0,0 +1,3 @@
|
||||
source "%val{runtime}/colors/default.kak"
|
||||
source "%val{runtime}/rc/base/markdown.kak"
|
||||
set buffer filetype markdown
|
1
test/indent/markdown/open-after-setext-heading-2/cmd
Normal file
1
test/indent/markdown/open-after-setext-heading-2/cmd
Normal file
@ -0,0 +1 @@
|
||||
o
|
2
test/indent/markdown/open-after-setext-heading-2/in
Normal file
2
test/indent/markdown/open-after-setext-heading-2/in
Normal file
@ -0,0 +1,2 @@
|
||||
Some Heading
|
||||
%(-)-----------
|
3
test/indent/markdown/open-after-setext-heading-2/out
Normal file
3
test/indent/markdown/open-after-setext-heading-2/out
Normal file
@ -0,0 +1,3 @@
|
||||
Some Heading
|
||||
------------
|
||||
|
3
test/indent/markdown/open-after-setext-heading-2/rc
Normal file
3
test/indent/markdown/open-after-setext-heading-2/rc
Normal file
@ -0,0 +1,3 @@
|
||||
source "%val{runtime}/colors/default.kak"
|
||||
source "%val{runtime}/rc/base/markdown.kak"
|
||||
set buffer filetype markdown
|
Loading…
Reference in New Issue
Block a user