# HG changeset patch # User Meredith Howard # Date 1468641707 14400 # Node ID 47b0510974fea2c3f1c528e5b3b3c149da4556ab # Parent 31081755a2be957e6a1c9eaab84a7a687fcc277c fix up for reply/compose cursor pos diff --git a/.vim/ftplugin/mail.vim b/.vim/ftplugin/mail.vim --- a/.vim/ftplugin/mail.vim +++ b/.vim/ftplugin/mail.vim @@ -1,16 +1,16 @@ -function IsReply() +function JumpAndInsert() if line('$') > 1 :/^$/ - :noh + :normal 2] :+1 + :exe 'startinsert' endif endfunction augroup mail_filetype autocmd! - autocmd VimEnter /tmp/mutt* :call IsReply() - autocmd VimEnter /tmp/mutt* :exe 'startinsert' + autocmd VimEnter /tmp/mutt* :call JumpAndInsert() augroup END setl textwidth=72