xref: /original-bsd/usr.bin/diction/style/style.sh (revision f2834164)
1#!/bin/sh -
2#
3# %sccs.include.proprietary.sh%
4#
5#	@(#)style.sh	8.1 (Berkeley) 06/06/93
6#
7
8L=/usr/libexec
9B=/usr/bin
10echo " " $*
11sflag=-s
12eflag=
13Pflag=
14nflag=
15lflag=
16lcon=
17rflag=
18rcon=
19mflag=-me
20mlflag=-ml
21kflag=
22for i in $*
23do case $i in
24-r) rflag=-r; shift; rcon=$1;shift;continue;;
25-l)lflag=-l; shift; lcon=$1;shift;continue;;
26-mm) mflag=-mm;shift;continue;;
27-ms) mflag=-ms;shift;continue;;
28-me) mflag=-me;shift;continue;;
29-ma) mflag=-ma;shift;continue;;
30-li|-ml) mlflag=-ml;shift;continue;;
31+li|-tt)mlflag=;shift;continue;;
32-p) sflag=-p;shift;continue;;
33-a) sflag=-a;shift;continue;;
34-e) eflag=-e;shift;continue;;
35-P) Pflag=-P;shift;continue;;
36-n) nflag=-n;shift;continue;;
37-N) nflag=-N;shift;continue;;
38-k) kflag=-k;shift;continue;;
39-flags) echo $0 "[-flags] [-r num] [-l num] [-e] [-p] [-n] [-N] [-a] [-P] [-mm|-ms] [-li|+li] [file ...]";exit;;
40-*) echo unknown style flag $i; exit;;
41*) break;;
42esac
43done
44$B/deroff $kflag $mflag $mlflag $* | $L/style1 | $L/style2 | $L/style3 $rflag $rcon $lflag $lcon $sflag $nflag $eflag $Pflag
45