#!/bin/csh -f

# mimeit -- mail base64-encoded stdin with content-type $1 to recipient $2 
# with subject $3
# All other arguments are passed on to splitmail

set ct="$1"
set to="$2"
set sub="$3"
shift
shift
shift
(echo Content-type: "$ct"; echo To: "$to" ; echo Subject: "$sub" ;  \
echo Content-Transfer-Encoding: base64 ; echo "" ;  \
mimencode -b ) | splitmail -d $*
