Command Reference Guide

__________________________________________________________________________________________________________________________________________________________________________________________________
__________________________________________________________________________________________________________________________________________________________________________________________________
STANDARD Printed by: Nora Chuang [nchuang] STANDARD
/build/1111/BRICK/man1/!!!intro.1
________________________________________________________________
___ ___
a
adjust(1) adjust(1)
NAME
adjust - simple text formatter
SYNOPSIS
adjust [-b][-c|-j|-r ] [-m column ][-t tabsize][files ...]
DESCRIPTION
The adjust command is a simple text formatter for filling, centering, left and right justifying, or only
right justifying text paragraphs, and is designed for interactive use. It reads the concatenation of input
files (or standard input if none are given) and produces on standard output a formatted version of its input,
with each paragraph formatted separately. If - is given as an input filename, adjust reads standard
input at that point (use --as an argument to separate - from options.)
adjust reads text from input lines as a series of words separated by space characters, tabs, or newlines.
Text lines are grouped into paragraphs separated by blank lines. By default, text is copied directly to the
output, subject only to simple filling (see below) with a right margin of 72, and leading spaces are converted
to tabs where possible.
Options
The adjust command recognizes the following command-line options:
-b Do not convert leading space characters to tabs on output; (output contains no tabs, even if
there were tabs in input).
-c Center text on each line. Lines are pre- and post-processed, but no filling is performed.
-j Justify text. After filling, insert spaces in each line as needed to right justify it (except in
the last line of each paragraph) while keeping the justified left margin.
-r After filling text, adjust the indentation of each line for a smooth right margin (ragged left
margin).
-mcolumn
Set the right fill margin to the given column number, instead of 72. Text is filled, and
optionally right justified, so that no output line extends beyond this column (if possible). If
-m0 is given, the current right margin of the first line of each paragraph is used for that
and all subsequent lines in the paragraph.
By default, text is centered on column 40. With -c, the -m option sets the middle column
of the centering ‘‘window’’, but -m0 auto-sets the right side as before (which then deter-
mines the center of the ‘‘window’’).
-ttabsize Set the tab size to other than the default (eight columns).
Only one of the -c, -j, and -r options is allowed in a single command line.
Details
Before doing anything else to a line of input text, adjust first handles backspaces, rubbing out preceding
characters in the usual way. Next, it ignores all non-printable characters except tab. It then expands all
tabs to spaces.
For simple text filling, the first word of the first line of each paragraph is indented the same amount as in
the input line. Each word is then carried to the output followed by one space. ‘‘Words’’ ending in
terminal_character[quote][closing_character] are followed by two spaces, where terminal_character is any
of
., :, ?,or!; quote is a single closing quote (
’ ) character or double-quote character ( " ), and close is
any of
), ],or}. Here are some examples:
end. of? sentence.’ sorts!" of.) words?"]
(adjust does not place two spaces after a pair of single closing quotes (’’ ) following a
terminal_character).
adjust starts a new output line whenever adding a word (other than the first one) to the current line
would exceed the right margin.
adjust understands indented first lines of paragraphs (such as this one) when filling. The
second and subsequent lines of each paragraph are indented the same amount as the second line of the
input paragraph if there is a second line, else the same as the first line.
Section 1−−10 − 1 − HP-UX Release 11i: December 2000
___
___