4
|
1 #!/bin/sh -
|
|
2 #
|
10
|
3 # $Id: tm-plain,v 1.2 1996/12/29 00:14:55 steve Exp $
|
4
|
4 #
|
|
5
|
|
6 if [ "$TM_TMP_DIR" = "" ]; then
|
|
7 TM_TMP_DIR=/tmp
|
|
8 export TM_TMP_DIR
|
|
9 fi
|
|
10 if [ "$5" = "" ]; then
|
|
11 filename="$TM_TMP_DIR/mime$$.pln"
|
|
12 else
|
|
13 filename="$TM_TMP_DIR/$5"
|
|
14 fi
|
|
15
|
|
16 case "$4" in
|
|
17 "play")
|
|
18 echo "$2; $3 ->"
|
|
19 tmdecode "$3" "$1" /dev/stdout
|
|
20 ;;
|
|
21 "extract")
|
|
22 echo "$2; $3 -> $filename"
|
|
23 echo "extract to $filename"
|
|
24 tmdecode "$3" "$1" $filename
|
|
25 ;;
|
|
26 "print")
|
|
27 echo "$2; $3 ->"
|
|
28 tmdecode "$3" "$1" /dev/stdout | lpr
|
|
29 ;;
|
10
|
30 esac
|