written by Kurt Shoens; add Berkeley copyright
[unix-history] / usr / src / usr.bin / fmt / fmt.1
CommitLineData
e1e4fcc9
KB
1.\" Copyright (c) 1980 The Regents of the University of California.
2.\" All rights reserved.
8c3a8b73 3.\"
e1e4fcc9
KB
4.\" Redistribution and use in source and binary forms are permitted
5.\" provided that the above copyright notice and this paragraph are
6.\" duplicated in all such forms and that any documentation,
7.\" advertising materials, and other materials related to such
8.\" distribution and use acknowledge that the software was developed
9.\" by the University of California, Berkeley. The name of the
10.\" University may not be used to endorse or promote products derived
11.\" from this software without specific prior written permission.
12.\" THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR
13.\" IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
14.\" WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
15.\"
16.\" @(#)fmt.1 6.3 (Berkeley) %G%
8c3a8b73 17.\"
9123ccac 18.TH FMT 1 ""
8c3a8b73
KM
19.UC
20.SH NAME
21fmt \- simple text formatter
22.SH SYNOPSIS
23.B fmt
fadf875b 24[ goal [ maximum ] ]
8c3a8b73
KM
25[
26name ...
27]
28.SH DESCRIPTION
29.I Fmt
30is a simple text formatter which reads the concatenation of input
fadf875b
KM
31files (or standard input if none are given) and produces on standard
32output a version of its input with lines as close to the goal length
33as possible without exceeding the maximum. The goal length defaults
34to 65 and the maximum to 75. The spacing at the beginning of the
35input lines is preserved in the output, as are blank lines and
36interword spacing.
8c3a8b73
KM
37.PP
38.I Fmt
39is meant to format mail messages prior to sending, but may also be useful
40for other simple tasks.
41For instance,
42within visual mode of the
43.I ex
44editor (e.g.
45.IR vi )
46the command
47.br
48 !}fmt
49.br
50will reformat a paragraph,
51evening the lines.
52.SH "SEE ALSO"
53nroff(1), mail(1)
54.SH AUTHOR
55Kurt Shoens
fadf875b
KM
56.br
57Liz Allen (added goal length concept)
8c3a8b73
KM
58.SH BUGS
59The program was designed to be simple and fast \- for more complex
60operations, the standard text processors are likely to be more appropriate.