vimd for dokuwiki todo

This commit is contained in:
Ville Rantanen
2023-12-03 17:32:16 +02:00
parent b7fd675ebc
commit c7cd2ec061

View File

@@ -1,7 +1,8 @@
function! Box_clear () function! Box_clear ()
mapclear! mapclear!
map <space> :<C-U>call Flip_box()<CR>j^ map <space> :<C-U>call Flip_box()<CR>j^
imap <C-b> [ ] imap <C-b> [ ]
imap <C-t> <todo> </todo>
imap <C-d> <C-R>=strftime('%y-%m-%d %H:%M')<CR> imap <C-d> <C-R>=strftime('%y-%m-%d %H:%M')<CR>
set laststatus=2 set laststatus=2
set statusline=%f\ %=\ ([x]\ spc,^bd)\ (%v,%l) set statusline=%f\ %=\ ([x]\ spc,^bd)\ (%v,%l)
@@ -13,6 +14,9 @@ function! Flip_box ()
s!\[ \]![xXx]!eg s!\[ \]![xXx]!eg
s!\[x\]![ ]!eg s!\[x\]![ ]!eg
s!\[xXx\]![x]!eg s!\[xXx\]![x]!eg
s!<todo>!<todo xXx>!eg
s!<todo #[^>]*>!<todo>!eg
s!<todo xXx>!<todo #q>!eg
endfunction endfunction
set filetype=markdown set filetype=markdown