taskwiki icon indicating copy to clipboard operation
taskwiki copied to clipboard

Improvement: CTRL+SPACE complete started task

Open MartyLake opened this issue 7 years ago • 6 comments

«When I hit CTRL+SPACE on a started task - [S] started task , I want to mark the task as complete.» Observed behavior: - [S] started task becomes - [ ][S] started task

If you can help me on how to do this, I can probably create a PR ! :) It seems like this shortcut is defined in vimwiki, ftplugin/vimwiki.vim l434 nmap <silent><buffer> <C-Space> <Plug>VimwikiToggleListItem

MartyLake avatar Apr 16 '18 12:04 MartyLake

The way to do it would be probably to remap the CTRL+SPACE to our command, which would run :TaskWikiDone if the line contains a task, and :VimwikiToggleListItem otherwise.

tbabej avatar Apr 18 '18 14:04 tbabej

Ok! How would you test that a line contains a task ? testing that it starts with "any number of space, dash, space, opening bracket" ?


Matthieu TALBOT [email protected]

+33 629 22 15 70 fr.linkedin.com/in/matthieutalbot http://www.soundcloud.com/Marty-Lake http://lifehacker.com/5028808/how-eom-makes-your-email-more-efficient

On 18 April 2018 at 16:49, Tomas Babej [email protected] wrote:

The way to do it would be probably to remap the CTRL+SPACE to our command, which would run :TaskWikiDone if the line contains a task, and :VimwikiToggleListItem otherwise.

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/tbabej/taskwiki/issues/175#issuecomment-382414072, or mute the thread https://github.com/notifications/unsubscribe-auth/ABMGSpaEHH1HrhRBgfU9c2wv-nj56Aqoks5tp1KRgaJpZM4TWbxt .

MartyLake avatar Apr 18 '18 15:04 MartyLake

Have a look into taskwiki/main.py:278.

tbabej avatar Apr 18 '18 16:04 tbabej

@MartyLake PR still coming here?

tbabej avatar Jul 15 '18 23:07 tbabej

@tbabej Hey, did not take the time to follow up with the PR, sorry. I just got used to replace the space with an X and save the buffer instead.

MartyLake avatar Aug 06 '18 14:08 MartyLake

i will take this one :) in fact, I have already a branch with most of the fix, stay tunned for the PR!

aaronfc avatar Apr 05 '20 17:04 aaronfc