672 xargs doesn't support -0
[illumos-gate.git] / usr / src / man / man1 / deroff.1
blob74f061b343db16d66d003670d889f795fa438163
1 '\" te
2 .\" Copyright (c) 1996, Sun Microsystems, Inc. All Rights Reserved.
3 .\" Copyright 1989 AT&T
4 .\" The contents of this file are subject to the terms of the Common Development and Distribution License (the "License").  You may not use this file except in compliance with the License.
5 .\" You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE or http://www.opensolaris.org/os/licensing.  See the License for the specific language governing permissions and limitations under the License.
6 .\" When distributing Covered Code, include this CDDL HEADER in each file and include the License file at usr/src/OPENSOLARIS.LICENSE.  If applicable, add the following below this CDDL HEADER, with the fields enclosed by brackets "[]" replaced with your own identifying information: Portions Copyright [yyyy] [name of copyright owner]
7 .TH DEROFF 1 "Sep 14, 1992"
8 .SH NAME
9 deroff \- remove nroff/troff, tbl, and eqn constructs
10 .SH SYNOPSIS
11 .LP
12 .nf
13 \fBderoff\fR [\fB-m\fR [m | s | l]] [\fB-w\fR] [\fB-i\fR] [\fIfilename\fR...]
14 .fi
16 .SH DESCRIPTION
17 .sp
18 .LP
19 \fBderoff\fR reads each of the \fIfilenames\fR in sequence and removes all
20 \fBtroff\fR(1) requests, macro calls, backslash constructs, \fBeqn\fR(1)
21 constructs (between \fB\&.EQ\fR and \fB\fR\fB\&.EN\fR\fB \fR lines, and between
22 delimiters), and \fBtbl\fR(1) descriptions, perhaps replacing them with white
23 space (blanks and blank lines), and writes the remainder of the file on the
24 standard output. \fBderoff\fR follows chains of included files (\fB\&.so\fR and
25 \fB\&.nx\fR \fBtroff\fR commands); if a file has already been included, a
26 \fB\&.so\fR naming that file is ignored and a \fB\&.nx\fR naming that file
27 terminates execution. If no input file is given, \fBderoff\fR reads the
28 standard input.
29 .SH OPTIONS
30 .sp
31 .ne 2
32 .na
33 \fB\fB-m\fR\fR
34 .ad
35 .RS 6n
36 The \fB-m\fR option may be followed by an \fBm\fR, \fBs\fR, or \fBl\fR. The
37 \fB-mm\fR option causes the macros to be interpreted so that only running text
38 is output (that is, no text from macro lines.)  The \fB-ml\fR option forces the
39 \fB-mm\fR option and also causes deletion of lists associated with the \fBmm\fR
40 macros.
41 .RE
43 .sp
44 .ne 2
45 .na
46 \fB\fB-w\fR\fR
47 .ad
48 .RS 6n
49 If the \fB-w\fR option is given, the output is a word list, one ``word'' per
50 line, with all other characters deleted. Otherwise, the output follows the
51 original, with the deletions mentioned above. In text, a ``word'' is any string
52 that \fIcontains\fR at least two letters and is composed of letters, digits,
53 ampersands (\fB&\fR), and apostrophes (\fB\&'\fR); in a macro call, however, a
54 ``word'' is a string that \fIbegins\fR with at least two letters and contains a
55 total of at least three letters. Delimiters are any characters other than
56 letters, digits, apostrophes, and ampersands. Trailing apostrophes and
57 ampersands are removed from ``words.''
58 .RE
60 .sp
61 .ne 2
62 .na
63 \fB\fB-i\fR\fR
64 .ad
65 .RS 6n
66 The  \fB-i\fR option causes  \fBderoff\fR to ignore  \fB\&.so\fR and
67 \fB\&.nx\fR commands.
68 .RE
70 .SH SEE ALSO
71 .sp
72 .LP
73 \fBeqn\fR(1), \fBnroff\fR(1), \fBtbl\fR(1), \fBtroff\fR(1), \fBattributes\fR(5)
74 .SH NOTES
75 .sp
76 .LP
77 \fBderoff\fR is not a complete \fBtroff\fR interpreter, so it can be confused
78 by subtle constructs. Most such errors result in too much rather than too
79 little output.
80 .sp
81 .LP
82 The \fB-ml\fR option does not handle nested lists correctly.