On Fri,May 09 03:14:PM, Jean-Rene David wrote:
> * Guy Gold [2014.05.09 13:58]:
> > send-hook '~t...@domain.com'  'set editor= "vim  -c \":r \!cat  
> > /path/to/file\""'
> 
> Is it me or is this a useless use of cat?
> 
> vim -c ':r !cat /path/to/file' <=> vim -c ':r /path/to/file'

Yes, and no. 
While issuing this command from the shell itself, or from vim
itself does not call for !cat, using this in a send-hook left me
no choice but to use !cat. 
If,"  vim -c ':r /path/to/file' " is used, what happens in mutt
is, vim gets two files to edit, "/path/to/file" and
/tmp/mutt-muttfile.being.edited. That , creates a mess of itself. 

I'm still far from solving this issue though, the initial !cat
works fine now, however- if I :wq from the editor into the 'ready
to send' screen in mutt, (where the From: and Subject: can be
edited), and, then I choose to go back an re-edit my email, the
!cat action takes place again - and that's not desired. 

-- 

GG

Reply via email to