Merge remote-tracking branch 'Screwtapello/markdown-indent-fixes'

This commit is contained in:
Maxime Coste 2017-08-02 00:29:00 +07:00
commit 9858053d97
25 changed files with 49 additions and 1 deletions

View File

@ -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

View File

@ -0,0 +1 @@
i<ret><esc>

View File

@ -0,0 +1 @@
>> > > block %(q)uote

View File

@ -0,0 +1,2 @@
>> > > block
>> > > quote

View File

@ -0,0 +1,3 @@
source "%val{runtime}/colors/default.kak"
source "%val{runtime}/rc/base/markdown.kak"
set buffer filetype markdown

View File

@ -0,0 +1 @@
a<ret><esc>

View File

@ -0,0 +1,2 @@
- parent
* some%( )child

View File

@ -0,0 +1,3 @@
- parent
* some
* child

View File

@ -0,0 +1,3 @@
source "%val{runtime}/colors/default.kak"
source "%val{runtime}/rc/base/markdown.kak"
set buffer filetype markdown

View File

@ -0,0 +1 @@
i<ret><esc>

View File

@ -0,0 +1 @@
> block %(q)uote

View File

@ -0,0 +1,2 @@
> block
> quote

View File

@ -0,0 +1,3 @@
source "%val{runtime}/colors/default.kak"
source "%val{runtime}/rc/base/markdown.kak"
set buffer filetype markdown

View File

@ -0,0 +1 @@
i<ret><esc>

View File

@ -0,0 +1 @@
**strong %(e)mphasis**

View File

@ -0,0 +1,2 @@
**strong
emphasis**

View File

@ -0,0 +1,3 @@
source "%val{runtime}/colors/default.kak"
source "%val{runtime}/rc/base/markdown.kak"
set buffer filetype markdown

View File

@ -0,0 +1 @@
o

View File

@ -0,0 +1,2 @@
Some Heading
%(=)===========

View File

@ -0,0 +1,3 @@
Some Heading
============

View File

@ -0,0 +1,3 @@
source "%val{runtime}/colors/default.kak"
source "%val{runtime}/rc/base/markdown.kak"
set buffer filetype markdown

View File

@ -0,0 +1 @@
o

View File

@ -0,0 +1,2 @@
Some Heading
%(-)-----------

View File

@ -0,0 +1,3 @@
Some Heading
------------

View File

@ -0,0 +1,3 @@
source "%val{runtime}/colors/default.kak"
source "%val{runtime}/rc/base/markdown.kak"
set buffer filetype markdown