1

After following this post: Saving email as file in mutt?, while in Pager view, pressing v and s in sequence will prompt the user to save the first attachment as a local file. As commented in the solution, there is no header info at all.

How to set up a macro that does the following?

  1. Save the message with header info to a local file;
  2. Use Vim to open such a file.

Also, I tried to pipe the message to Vim, by pressing | vim<enter> in Pager view. It does get the text to Vim, but that Vim session only stayed alive for seconds.

llinfeng
  • 123
  • you could use e to and set EDITOR environmental variable to vim – mrajner Jun 04 '19 at 13:05
  • @mrajner, thank you! How may I re-assign such action to another key? I tried bind index,pager i edit, but the new "mapping/binding" looks different from the native e's mapping ==> the latter has been mapped to edit read? – llinfeng Jun 05 '19 at 20:59

1 Answers1

0

Because you're piping the message to vim you have to tell vim that it should read from /dev/stdout.

Try following:

| vim -<enter>
Jakub Jindra
  • 1,462