
history | 669
Bash and Korn
This is the Title of the Book, eMatter Edition
Copyright © 2006 O’Reilly & Associates, Inc. All rights reserved.
help
help [-s] [pattern]
Bash only. Print usage information on standard output for each
command that matches pattern. The information includes descrip-
tions of each command’s options. With the -s option, print only
brief usage information.
Examples
$ help -s cd Short help
cd: cd [-L|-P] [dir]
$ help true Full help
true: true
Return a successful result.
hist
hist [options] [first [last]]
hist -s [old=new] [command]
ksh93 only. Display or edit commands in the history list. (Use only
one of -l or -s.) first and last are numbers or strings specifying the
range of commands to display or edit. If last is omitted, hist applies
to a single command (specified by first). If both first and last are
omitted, hist edits the previous command or lists the last 16. The
second form of hist takes a history command, replaces old with
new, and executes the modified command. If no strings are speci-
fied, command is just reexecuted. If no command is given either, the
previous command is reexecuted. command is a number or string
like first. See the examples in the earlier section “Command
History.”
Options
-e [editor]
Invoke editor to edit the specified history commands. The
default editor is set by the shell variable HISTEDIT. If that
variable is not set, FCEDIT is used. If neither is set, ...