aboutsummaryrefslogtreecommitdiff
path: root/vim/plugin
diff options
context:
space:
mode:
authorTom Ryder <tom@sanctum.geek.nz>2017-11-11 01:05:15 +1300
committerTom Ryder <tom@sanctum.geek.nz>2017-11-11 01:05:15 +1300
commitf9600abb2182b467dfd24ce16e3eebed26723338 (patch)
tree4804a2e6ed86f1e3a33e1ab3b8a3ea11be44fb7f /vim/plugin
parentfe8e94bea39895f2544ae83916da83a4f2affa21 (diff)
downloaddotfiles-f9600abb2182b467dfd24ce16e3eebed26723338.tar.gz
dotfiles-f9600abb2182b467dfd24ce16e3eebed26723338.zip
Move mutt_mail.vim line select logic into plugin
This makes the configuration shorter and easier to read.
Diffstat (limited to 'vim/plugin')
-rw-r--r--vim/plugin/mail_mutt.vim15
1 files changed, 15 insertions, 0 deletions
diff --git a/vim/plugin/mail_mutt.vim b/vim/plugin/mail_mutt.vim
index 67444e4d..9bb4abd4 100644
--- a/vim/plugin/mail_mutt.vim
+++ b/vim/plugin/mail_mutt.vim
@@ -39,3 +39,18 @@ endfunction
command -nargs=0 -range=%
\ MailMutt
\ call <SID>MailMutt(<line1>, <line2>)
+
+" Mapping to mail current line in normal mode
+nnoremap <silent> <unique>
+ \ <Plug>MailMuttLine
+ \ :<C-U>.MailMutt<CR>
+
+" Mapping to mail whole buffer in normal mode
+nnoremap <silent> <unique>
+ \ <Plug>MailMuttBuffer
+ \ :<C-U>%MailMutt<CR>
+
+" Mapping to mail selected lines in visual/select mode
+vnoremap <silent> <unique>
+ \ <Plug>MailMuttSelected
+ \ :MailMutt<CR>