xref: /original-bsd/usr.bin/fmt/fmt.1 (revision 95a66346)
1.\" Copyright (c) 1980, 1990 The Regents of the University of California.
2.\" All rights reserved.
3.\"
4.\" %sccs.include.redist.man%
5.\"
6.\"     @(#)fmt.1	6.7 (Berkeley) 03/14/91
7.\"
8.Vx
9.Vx
10.Dd
11.Dt FMT 1
12.Sh NAME
13.Nm fmt
14.Nd simple text formatter
15.Sh SYNOPSIS
16.Nm fmt
17.Ob
18.Ar goal
19.Op Ar maximum
20.Oe
21.Op name ...
22.Sh DESCRIPTION
23.Nm Fmt
24is a simple text formatter which reads the concatenation of input
25files (or standard input if none are given) and produces on standard
26output a version of its input with lines as close to the
27.Ar goal
28length
29as possible without exceeding the maximum.  The
30.Ar goal
31length defaults
32to 65 and the maximum to 75.  The spacing at the beginning of the
33input lines is preserved in the output, as are blank lines and
34interword spacing.
35.Pp
36.Nm Fmt
37is meant to format mail messages prior to sending, but may also be useful
38for other simple tasks.
39For instance,
40within visual mode of the
41.Xr ex 1
42editor (e.g.
43.Xr vi 1 )
44the command
45.Pp
46.Dl \&!}fmt
47.Pp
48will reformat a paragraph,
49evening the lines.
50.Sh SEE ALSO
51.Xr nroff 1 ,
52.Xr mail 1
53.Sh HISTORY
54.Nm Fmt
55appeared in 3 BSD.
56.Sh AUTHOR
57Kurt Shoens
58.br
59Liz Allen (added goal length concept)
60.Sh BUGS
61The program was designed to be simple and fast \- for more complex
62operations, the standard text processors are likely to be more appropriate.
63