Museum

Home

Lab Overview

Retrotechnology Articles

⇒ Online Manual

Media Vault

Software Library

Restoration Projects

Artifacts Sought

Related Articles

nroff(1)

mail(1)

FMT(1)  —  USER COMMANDS

NAME

fmt − simple text formatter

SYNOPSIS

fmt [ −width ] [ −c ] [ input-file ...  ]

DESCRIPTION

fmt is a simple text formatter.  It joins and fills input lines to produce output lines of up to 72 characters by default.  fmt concatenates the input-files listed as arguments.  If none are given, fmt accepts text from the standard input. 

Blank lines are preserved in the output, as is spacing between words. 

Normally, if the left-hand margin of a line is indented, that indention is preserved in the output.  Input lines with differing indention aren’t normally joined. 

fmt is meant to format mail messages before sending, but may also be useful for other simple tasks.  For instance, while in the vi text editor, the command:

!}fmt

reformats a paragraph, making the lines reasonably even in length. 

fmt does not fill lines beginning with  . or From: for compatibility with nroff(1) and mail(1).

OPTIONS

−width
Fill output lines to up to width columns wide. 

−cCrown margin mode (useful for tagged paragraphs).  fmt preserves the indention of the first two lines in each paragraph.  The left margin of the third and subsequent lines is aligned with that of the second. 

SEE ALSO

nroff(1), mail(1)

Sun Release 3.2  —  Last change: 17 February 1986

Typewritten Software • bear@typewritten.org • Edmonds, WA 98026