Added all of the MH sources, including RCS files, in
[mmh] / docs / historical / mh-6.8.5 / support / general / RCS / pgped.sh,v
1 head    1.2;
2 access;
3 symbols;
4 locks; strict;
5 comment @# @;
6
7
8 1.2
9 date    95.12.06.21.00.46;      author jromine; state Exp;
10 branches;
11 next    1.1;
12
13 1.1
14 date    95.12.06.20.57.55;      author jromine; state Exp;
15 branches;
16 next    ;
17
18
19 desc
20 @@
21
22
23 1.2
24 log
25 @more pgp fixes from mtr
26 @
27 text
28 @: run this script through /bin/sh
29
30 if [ "$1" = -sign ]; then
31     FLAGS=sat
32     TEXT=T
33     shift
34 else
35     FLAGS=esat
36     TEXT=F
37 fi
38
39 if [ "$#" != 1 ]; then
40     echo "usage: What now? ed pgped" 1>&2
41     exit 1
42 fi
43 DRAFT=$1
44
45 trap "rm -f $DRAFT.1 $DRAFT.2 $DRAFT.2.asc" 0 1 2 3 13 15
46
47 USERS="`stclsh -nointerface -messaging -messagebody $DRAFT -file @@LIB/pgped.tcl $DRAFT.1 $DRAFT.2 $TEXT`"
48
49 if [ ! -s $DRAFT.1 -o ! -s $DRAFT.2 ]; then
50     exit 1
51 fi
52
53 if pgp -$FLAGS $DRAFT.2 $USERS; then
54     mv $DRAFT `dirname $DRAFT`/,`basename $DRAFT`
55
56     cat $DRAFT.1 $DRAFT.2.asc > $DRAFT
57
58     exit 0
59 fi
60
61 exit 1
62 @
63
64
65 1.1
66 log
67 @Initial revision
68 @
69 text
70 @d5 1
71 d9 1
72 d20 1
73 a20 1
74 USERS="`stclsh -nointerface -messaging -messagebody $DRAFT -file @@LIB/pgped.tcl $DRAFT.1 $DRAFT.2`"
75 @