summaryrefslogtreecommitdiffstats
path: root/pgpewrap
blob: bc1a8e0ed90826d58f8d74dfd3bb8b9a6282f563 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
#!/bin/sh --

cmd=$1
pfx=""

die() {
	echo "Command line usage: $0 [flags] -- prefix [recipients]" >& 2
	exit 1
}

while shift 2> /dev/null && test -n "$1" ; do
	if test "$1" = "--" ; then
		shift || die
		pfx="$1"
		shift || die
	fi
	cmd="$cmd $pfx $1"
done

exec $cmd