projects
/
elisp
/
tm.git
/ blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
history
|
raw
|
HEAD
tm4.7.0.
[elisp/tm.git]
/
methods
/
tm-plain
1
#!/bin/csh
2
3
if( $5 == "" ) then
4
set filename="/tmp/mime$$.pln"
5
else
6
set filename = /tmp/$5
7
endif
8
9
echo "$2; $3 -> $filename"
10
11
switch ( $3 )
12
case "7bit":
13
case "8bit":
14
case "binary":
15
cp $1 $filename
16
breaksw
17
case "base64":
18
decode-b < $1 > $filename
19
breaksw
20
case "quoted-printable":
21
mmencode -q -u $1 > $filename
22
breaksw
23
default:
24
echo "unkown encoding"
25
exit -1
26
endsw
27
28
/bin/rm $1
29
30
switch( $4 )
31
case "play":
32
cat $filename
33
/bin/rm $filename
34
breaksw
35
case "extract":
36
echo "extract to $filename"
37
breaksw
38
case "print":
39
txt2ps -n $filename | lpr
40
/bin/rm $filename
41
breaksw
42
endsw