Command Reference Guide

__________________________________________________________________________________________________________________________________________________________________________________________________
__________________________________________________________________________________________________________________________________________________________________________________________________
STANDARD Printed by: Nora Chuang [nchuang] STANDARD
/build/1111/BRICK/man1/!!!intro.1
________________________________________________________________
___ ___
e
ex(1) ex(1)
A copy of the specified lines (range) is placed after the specified destination line; line 0
specifies that the lines are to be placed at the beginning of the work area. (The letter t
is an alternative abbreviationfor the copy command.)
crypt cr[ypt]
X
The user is prompted for a key with which to enter encryption mode. This command
can also be used to change the key entered from a previous crypt command or the -x
command line option. If no key is supplied in response to the prompt (that is, only car-
riage return is pressed), encryption mode is canceled and the work area is written out in
plain-text form by subsequent write commands.
While in encryption mode, all file input is decrypted using the current key. However,
while an input file is being processed, if a block of text (approximately 1024 bytes) is
encountered that contains only 7-bit ASCII characters, that block of text is assumed to
be plain-text and is not decrypted. All file output, except that piped via a ! shell escape
to another command, is encrypted using the current key.
The temporary file used by the editor to manage the work area is not encrypted until
the current work area is discarded (or written out) and editing begins on a new file.
When creating a new file that requires encryption protection, ensure that the work area
file is also encrypted by specifying the -x option when invoking the editor.
cr[ypt]
C
Encryption option. Same as the X command, except that all text read in is assumed to
have been encrypted.
delete range d[elete] buffer count
The specified lines are deleted from the work area. If a named buffer is specified, the
deleted text is saved in it. If no buffer is specified, the unnamed buffer is used (that is,
the buffer where the most recently deleted or yanked text is placed by default). The
new current line is the line after the deleted lines or the last line of the file if the deleted
lines were at the end of the file.
edit e[dit][!][+ line] file
ex[!][+ line] file
Begin editing a new file (ex is an alternative name for the edit command). If the
current work area has been modified since the last write, a warning is printed and the
command is aborted. This action can be overridden by appending the character
! to the
command (
e! file). The current line is the last line of the work area unless it is exe-
cuted from within vi, in which case the current line is the first line of the work area. If
the +line option is specified, the current line is set to the specified position, where line
can be a number (or $) or specified as /re or ?re.
file f[ile]
Print the current file name and other information, including the number of lines and the
current position.
global range g[lobal][!] /re/ command...
range v/re/ command...
Perform command on lines within range (or on the entire work area if no range is given)
that contain re. First mark the lines within the given range that match the pattern re.
If the pattern is omitted, the more recently set of either the substitution string or the
scanning string is used (see Regular Expressions above). Then the given commands are
executed with
. set to each marked line. Any character other than a letter or a digit
can be used to delimit the pattern instead of the /.
command can be specified on multiple lines by hiding new-lines with a backslash. If
command is omitted, each line is printed. append, change, and insert commands
are allowed; the terminating dot can be omitted if it ends command or commands. The
visual command is also permitted (unless the global command itself has been
issued from visual mode), and takes input from the terminal. (If command contains a
visual-mode command (that is, open or visual), the visual-mode command must be
Section 1−−246 − 6 − HP-UX Release 11i: December 2000
___
___