You can search for and preview a command from the history list without having to re-run it.
You can also list commands from the history list using the fc (fix command ) command.
EMACS
Preview previous command ^P in the list.
Preview next command in ^N the list.
Search backward up the ^Rstring command history.
Search forward down the ^Sstring command history.