taskwiki icon indicating copy to clipboard operation
taskwiki copied to clipboard

Run "task sync" on loading / exiting buffer

Open abers opened this issue 6 years ago • 2 comments

Unsure if this is already possible, couldn't see anything in the help file, but it would be useful if could setup taskwiki to run "task sync" on before loading and after exiting buffers with taskwiki viewports.

abers avatar Jun 17 '19 10:06 abers

No, this is not part of current functionality. I can see how this is helpful, however, it could slow down the user experience (task sync can be particularly slow on bad internet connections).

I could see this added if somebody is willing to contribute a small patch, however it should be optional and disabled as default

tbabej avatar Aug 06 '19 11:08 tbabej

To sync tasks every time you open vimwiki or leave vim/nvim, add this to your .vimrc:

augroup TaskWiki
  autocmd!
  autocmd BufEnter vimwiki :TWSync
  autocmd VimLeave * :TWSync
augroup END

It assumes you have installed the vim-taskwarrior plugin.

ludenticus avatar May 02 '21 14:05 ludenticus