summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--vim/vimrc11
1 files changed, 11 insertions, 0 deletions
diff --git a/vim/vimrc b/vim/vimrc
index c9b4846..1fb26aa 100644
--- a/vim/vimrc
+++ b/vim/vimrc
@@ -45,6 +45,17 @@ set tags+=./tags
set background=dark
set completeopt=menuone,longest
+" Function to allow adding a line of text to taskwarrior
+function! TaskWarriorAddCurrentLine()
+ let current_line = getline('.')
+ silent execute ":!task add " . shellescape(current_line)
+ redraw!
+ echo "Task added: " . current_line
+ delete
+endfunction
+
+nnoremap <leader>q :call TaskWarriorAddCurrentLine()<CR>
+
" colorscheme goes here, outside source control
source ~/.vim/ephemera.vim
highlight SignColumn guibg=blue ctermbg=black