|
Note: Mutt exports text/* attachements in the character set/encoding used by the terminal it runs on. By using text/html attachements, there is a problem with this that needs to be circumvented: the html attachement can contain a key for specifying the character encoding of the html text, which is not neccessarily in accordance with the terminal encoding (the sender of the email does not know, what encoding mutt on the recieving end uses). Thus viewing these attachements with text encoded in the terminal encoding will fail. Work arounds: # tell the html-to-text converter (e.g. lynx) to ignore the html tag specifying the encoding (as done above) # re-encode the file using the correct character set. This can be done by a script using iconv [Bugreport with attached script] |
|
Mutt does not support quoting the first part and attaching the rest of the parts. Just add your comments like you were sending a new message. Another way is to go to the attachment-menu, tag all attachments you want to forward and invoke "tag-prefix" + |
|
Go to the attachment-menu, tag all attachments you want to forward and also tag the text part of the e-mail. Then invoke "tag-prefix" + |
Mutt 1.5.13 (2006-08-11):
View attachments, tag the ones you want to save, then use "tag-save" ("<tag-prefix><save-entry>"). Enter the directory to save under (no filename) and you'll be prompted: "File is a directory, save under it? [(y)es, (n)o, (a)ll]". The "a" option does what you want it to, and you get a chance to approve each save individually as well (in case you want to change a filename here or there).
Another solution that will work:
Quit mutt, then start mutt in the directory you want to save them, then enter "view attachments" mode, "tag" them all and then save them. See '?' on-line help for the keys to the functions.
Or define these macro:
macro attach W <save-entry><kill-line>/home/gawron/attachments/ macro attach E <save-entry><kill-line>/home/gawron/attachments/<enter>This will either save automatically (E) to a given dir with a single keystrike, or (W) give you a default path to either confirm or expand and then to save. As with all MuttGuide/Macros, they can't be used with tga-prefix.
test=test -n "$DISPLAY"
Don't be confused by the second "test," it's just one alias of the "[" program, so the command 'test -n "$DISPLAY"' is the same as '[ -n "$DISPLAY" ]'.
An example with text files then would be to add the following lines to your ~/.mailcap:
# If $DISPLAY is set, open it in 'xless,' the X11 version of classic 'less' text/*; xless '%s'; test=test -n "$DISPLAY" # If it's not set, we can't use X, so fall back on the usual console pager, 'less' text/*; less '%s'
Only one "test=" field is allowed per line, so every association on a line is linked to the "success" of that field. The next example uses this to define numerous fields for each of the X running/X not running lines:
#If $DISPLAY is set, use X-based counterparts text/html; mozilla %s; test=test -n "$DISPLAY"; edit=gvim; compose=gvim; nametemplate=%s.html #Fallback if X isn't available text/html; w3m -v -F -T text/html %s; edit=vim; compose=vim; nametemplate=%s.html; needsterminal
in mailcap:
##this is used when (v)iewing a text/html attachment: ##allowing you to browse and "click" links ##order matters the first entry which passes the test is used #gui browser if $DISPLAY is set text/html; mozilla %s; test=test -n "$DISPLAY"; nametemplate=%s.html #text browser otherwise text/html; w3m -v -F -T text/html %s; nametemplate=%s.html; needsterminal ##auto_view will use the entry with the copiousoutput part: text/html; lynx -stdin -dump -force_html ; copiousoutputin muttrc:
#if there is only html dump that auto_view text/html muttrc: # this helps with multipart messages alternative_order text/plain text/html
Note: Mutt exports text/* attachements in the character set/encoding used by the terminal it runs on. By using text/html attachements, there is a problem with this that needs to be circumvented: the html attachement can contain a key for specifying the character encoding of the html text, which is not neccessarily in accordance with the terminal encoding (the sender of the email does not know, what encoding mutt on the recieving end uses). Thus viewing these attachements with text encoded in the terminal encoding will fail. Work arounds:
For images you can use "aview" from the "aalib" project: http://aa-project.sourceforge.net/
However, you'll need to patch it to use it as filter to display with mutt's built-in pager.
Seriously, if you really must, use something like openOffice or some other simpler MuttTools like antiword, or have a look at Gary Johnson's UserPages.
In 1.5.X there is a new setting that helps with application/octet-stream attachments. mime_lookup. See [manual section 5.6]
mime_lookup application/octet-streamEverybody should set this.
set mime_forward=yes set mime_forward_rest=yesto your ~/.muttrc. This will cause Mutt to attach the message rather than quoting it in the body of the message.