mirror of
https://git.notmuchmail.org/git/notmuch
synced 2025-01-03 07:11:41 +01:00
vim: don't remove headers until after parsing them
This commit is contained in:
parent
fd805c16c3
commit
e13bdc2c0e
1 changed files with 6 additions and 2 deletions
|
@ -939,8 +939,6 @@ function! s:NM_compose_send()
|
||||||
let line = getline(lnum)
|
let line = getline(lnum)
|
||||||
endwhile
|
endwhile
|
||||||
let body_starts = lnum
|
let body_starts = lnum
|
||||||
exec printf('0,%dd', body_starts)
|
|
||||||
write
|
|
||||||
|
|
||||||
"[-a header] [-b bcc-addr] [-c cc-addr] [-s subject] to-addr
|
"[-a header] [-b bcc-addr] [-c cc-addr] [-s subject] to-addr
|
||||||
let cmd = ['mail']
|
let cmd = ['mail']
|
||||||
|
@ -972,6 +970,12 @@ function! s:NM_compose_send()
|
||||||
endfor
|
endfor
|
||||||
call extend(cmd, tos)
|
call extend(cmd, tos)
|
||||||
|
|
||||||
|
" TODO: make sure we have at least one target
|
||||||
|
" TODO: ask about empty jubject, etc
|
||||||
|
|
||||||
|
exec printf('0,%dd', body_starts)
|
||||||
|
write
|
||||||
|
|
||||||
call map(cmd, 's:NM_shell_escape(v:val)')
|
call map(cmd, 's:NM_shell_escape(v:val)')
|
||||||
let cmdtxt = join(cmd) . '< ' . fname
|
let cmdtxt = join(cmd) . '< ' . fname
|
||||||
let out = system(cmdtxt)
|
let out = system(cmdtxt)
|
||||||
|
|
Loading…
Reference in a new issue