HP-UX Reference (11i v3 07/02) - 1 User Commands N-Z (vol 2)

s
sh-posix(1) sh-posix(1)
^O Execute the current line and fetch the next line relative to current line from the his-
tory file.
M-digits Define a numeric parameter. The digits are taken as a parameter to the next com-
mand. The commands that accept a parameter are erase,
ˆB, ˆC, ˆD, ˆF, ˆK, ˆN,
^P, ˆR, ˆ], M-ˆH,
M-., M-_, M-b, M-c, M-d, M-f, M-h, and M-l.
M-letter Your alias list is searched for an alias by the name
_letter (underscore-letter). If an
alias of this name is defined, its value is inserted on the input queue. This letter must
not be one of the above metafunctions.
M-. The last word of the previous command is inserted on the line. If preceded by a
numeric parameter, the value of this parameter determines which word to insert
rather than the last word.
M-_ Same as M-..
M-* Attempt file name generation on the current word.
M-ˆ[ File name completion (meta-escape). Replaces the current word with the longest com-
mon prefix of all file names matching the current word with an asterisk appended. If
the match is unique, a
/ is appended if the file is a directory and a space is appended
if the file is not a directory.
M-= List files matching current word pattern as if an asterisk were appended.
^U Multiply parameter of next command by 4.
\ Escape next character. Editing characters and your erase, kill, and interrupt charac-
ters may be entered in a command line or in a search string, if preceded by a
\. The
\ removes the next character’s editing features (if any).
^V Display version of the shell.
M-# Insert a # at the beginning of the line and execute it. This causes a comment to be
inserted in the history file.
vi Editing Mode
The editor starts in insert mode until an escape (ESC) is received. This puts you in control mode in which
you can move the cursor and perform editing commands. A return in either mode sends the line.
Most control commands accept an optional repeat count prior to the command.
In vi mode on most systems, canonical processing is initially enabled and the command is echoed again if
the speed is 1200 baud or greater and contains any control characters, or if less than one second has
elapsed since the prompt was printed. The escape (ESC) character terminates canonical processing for the
remainder of the command and you can then modify the command line. This scheme has the advantages of
canonical processing with the typeahead echoing of raw mode.
Setting the viraw option always disables canonical processing on the terminal. This mode is implicit for
systems that do not support two alternate end-of-line delimiters, and may be helpful for certain terminals.
Insert Edit Commands
By default, the editor is in insert mode.
erase Delete previous inserted character. The erase character is user-definable with the
stty command; it is usually set to ˆH. The system default is #.
kill Delete all current inserted characters. The kill character is user-definable with the
stty command; it is usually set to ˆX or ˆU. The system default is @.
\ Escape the next erase or kill character.
eof Terminate the shell if the current line is null. The eof character is user-definable with
the stty command; it is usually set to ˆD. The system default is ˆD.
^V Escape next character. Editing characters and erase or kill characters may be entered
in a command line or in a search string if preceded by a ˆV, which removes the next
characters editing features (if any).
^W Delete the previous blank-separated word.
HP-UX 11i Version 3: February 2007 23 Hewlett-Packard Company 265