Open System Services Shell and Utilities Reference Manual (G06.25+, H06.03+)

User Commands (d - f) ex(1)
replaces the specied lines.
[range] < [count][flags]
Shifts the specied lines to the left; the number of character positions to be shifted is
determined by the shiftwidth editor option. Only leading spaces are lost in shifting;
other characters are not affected. The current line is the last line changed.
[range] > [count][flags]
Shifts the specied lines to the right, by inserting spaces, using tabs where possible, as
determined by the shiftwidth editor option. Empty lines are not changed. The current
line is the last line changed.
[range] & [options][count][flags]
[range] s[ubstitute][options][count][flags]
[range][options][count][flags]
Repeats the previous substitute subcommand, as if & were replaced by the previous
s/pattern/repl/ subcommand. (The same effect can be obtained by omitting the
/pattern/repl/ string in the substitute subcommand.) The version of the subcommand
using (tilde) is the same as & and s, but the pattern used is the last regular expression
used in any subcommand, not necessarily the one used in the last substitute subcom-
mand. For example, in the following sequence, the (tilde) is equivalent to
s/green/blue/:
s/red/blue/
/green
[line] = [flags]
Writes the line number of the specied line (the default is the last line). The current line
position is not affected.
<Ctrl-d>
Writes the next n lines, where n is the value of the editor option scroll. The subcom-
mand is invoked with the End-of-File character. The current line is the last line written.
@@ buffer
* buffer Executes each line of the named buffer as an ex subcommand. If no buffer is specied,
or is specied as @@ or *, the last buffer executed is used. If there is no last buffer, an
error occurs.
# Displays addressed lines with line numbers
" Starts comment
<Return>
Displays next line
The ex Subcommand Addresses
$ The last line
+ The next line
- The previous line
+n The nth line forward
527188-003 Hewlett-Packard Company 3115