[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kmail-devel
Subject:    Re: uuencoded files
From:       Marc Mutz <Marc.Mutz () uni-bielefeld ! de>
Date:       2001-05-05 12:02:05
[Download RAW message or body]

Michael Häckel wrote:
> 
<snip>
> You don't have to write one.
> Only use "filter app" and "uudecode" as application.
<snip>

Last time I used uudecode, this would cause you to lose all your emails!
uudecode happily takes input on stdin, but it won't put anything on
stdout that resembles a mail. But 'filter app' (new label: 'pipe
through') expects the modified message on stdout. The only way to
automatically filter out uuencoded stuff is to make the somthing like
the following script and use that as "filter app" (untested!):

#!/bin/bash

export DL_DIR=~/tmp
TMPFILE=$(mktemp -q $DL_DIR/uu-download.XXXXXX) || exit 1
if tee "$TMPFILE.uuencoded"; then
  if uudecode -o $TMPFILE $TMPFILE.uuencoded; then
    rm -f $TMPFILE.uuencoded
    exit 0
  fi
fi

rm -f $TMPFILE $TMPFILE.uuencoded
exit 1

Marc

-- 
Marc Mutz <Marc@Mutz.com>     http://EncryptionHOWTO.sourceforge.net/
University of Bielefeld, Dep. of Mathematics / Dep. of Physics

PGP-keyID's:   0xd46ce9ab (RSA), 0x7ae55b9e (DSS/DH)


_______________________________________________
Kmail Developers mailing list
Kmail@master.kde.org
http://master.kde.org/mailman/listinfo/kmail

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic