From 429a26e68f863afb306d6b7ea24892b6f580b384 Mon Sep 17 00:00:00 2001 From: Teddy Wing Date: Thu, 28 Apr 2016 18:37:57 -0400 Subject: Allow any action on any TODO type Previously you could only mark `-`-type TODOs as [Complete, Partially Complete, Deleted]. Now you can mark any type of TODO (`-`, `_`, `!`, `x`, `S`, `v`) as any of the above three states. --- ftplugin/todo.vim | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/ftplugin/todo.vim b/ftplugin/todo.vim index 323e5ec..83d6c00 100644 --- a/ftplugin/todo.vim +++ b/ftplugin/todo.vim @@ -6,9 +6,9 @@ let b:did_ftplugin = 1 nnoremap TwodoNewTodoBelow o- nnoremap TwodoNewTodoAbove O- -nnoremap TwodoMarkComplete m`:s/\v^(\s*)- /\1v / \| nohlsearch`` -nnoremap TwodoMarkDeleted m`:s/\v^(\s*)- /\1x / \| nohlsearch`` -nnoremap TwodoMarkPartiallyCompleted m`:s/\v^(\s*)- /\1S / \| nohlsearch`` +nnoremap TwodoMarkComplete m`:s/\v^(\s*)[-_!xS] /\1v / \| nohlsearch`` +nnoremap TwodoMarkDeleted m`:s/\v^(\s*)[-_!vS] /\1x / \| nohlsearch`` +nnoremap TwodoMarkPartiallyCompleted m`:s/\v^(\s*)[-_!xv] /\1S / \| nohlsearch`` nnoremap TwodoRemoveOldTodos :g/^\s*[vx] /d \| nohlsearch if !hasmapto('TwodoNewTodoBelow') || !maparg('n', 'n') -- cgit v1.2.3