Re: Mailcap question
On 19Jun2006 13:07, kyle wheeler <kyle-mutt@xxxxxxxxxxxxxx> wrote:
| On Monday, June 19 at 06:00 PM, quoth Jos? G. Juanino:
| > It does not work for me at least. I have the following entry in my
| > .mailcap file:
| >
| > text/html; dillo %s >/dev/null 2>&1 </dev/null & ; description "HTLM Files"
| >
| > and dillo complains about the input file has vanished. I think mutt
| > removes the file when no process holds the file open, as it uses the
| > unlink system call after the temp file is created.
|
| Yeah... mutt does that. The way around it is to use something like a
| protector script that does its own file management/cleanup. For
| example, if you create this script (let's call it ~/.muttspawn.sh,
| just for example's sake):
|
| #!/bin/sh
| file="$1"
| shift
| cp "$file" "$file.saved"
| "$@" "$file" >/dev/null 2>&1
Shouldn't this -^ be "$file.saved" ?
| rm "$file.saved"
|
| ...and then in your .mailcap you can put:
|
| text/html; ~/.muttspawn.sh %s dillo & ; description "HTML Files"
|
| And it should Just Work (tm).
Or am I missing some subtlety here? (I've not tried running this.)
--
Cameron Simpson <cs@xxxxxxxxxx> DoD#743
http://www.cskk.ezoshosting.com/cs/
I am a Bear of Very Little Brain and long words Bother Me.
- Winnie-the-Pooh