contrib/plan9/9mail
author Augie Fackler <augie@google.com>
Fri, 11 Mar 2016 11:24:50 -0500
changeset 28483 6f38ec428a19
parent 19613 4bfd3c7160d9
permissions -rw-r--r--
httppeer: do less splitting on httpheader value We only care about the first value split off, so only split off the first value.

#!/bin/rc
# 9mail - Mercurial email wrapper for upas/marshal

fn usage {
	echo >[1=2] usage: mercurial/9mail -f from to [cc]
	exit usage
}

from=()
cc=()
to=()

switch($1){
case -f
	from=$2
case *
	usage
}

to=($3)
if(~ $#* 4)
	cc=(-C $4)

upasname=$from
upas/marshal $cc $to