The last thing I needed was some KDE front end - and Kerry is nice enough.
But there was one flaw - I do not like neither Thunderbird nor Evolution. And the way Kerry tried to open emails was resulting in new emails with the content I wanted to read as attachments.
The solution is quite simple - write own wrapper for KMail to handle that. Since I did not know at first wheather the content of the email is piped to the program or just referenced, I make a small script that handles both ways. I hope others will find it usefull.
#!/bin/sh
if [ ! $1 ];
then
TMPFILE=`mktemp -q /tmp/emailpreview.XXXXXX`
if [ $? -ne 0 ]; then
echo "$0: Can’t create temp file, exiting..."
exit 1
fi
while read -u 0 TMP
do
echo "$TMP" >> $TMPFILE
done
else
TMPFILE=$1
fi
/usr/bin/kmail --view "file://$TMPFILE"
if [ ! $1 ]; then
rm -f $TMPFILE
fi
1 comment:
This tip is very useful. I have been searching a way to read individual message for a couple of days. This is the easiest method. Thanks.
Post a Comment