java.lang.Object
org.springframework.shell.core.command.AbstractCommand
org.springframework.shell.jline.command.History
All Implemented Interfaces:
Command

public class History extends AbstractCommand
A command that displays all previously run commands, optionally dumping them to a file readable by Script.
Author:
Eric Bottard, Mahmoud Ben Hassine
  • Constructor Details

    • History

      public History(org.jline.reader.History jLineHistory)
  • Method Details

    • getHelp

      public String getHelp()
      Description copied from interface: Command
      Get the help text of the command. It is reported as the DESCRIPTION section of the detailed help message of the command, which is omitted when the text is empty. Unlike Command.getDescription(), which is a one liner shown in the list of available commands, the help text is meant to be a longer explanation of what the command does.
      Specified by:
      getHelp in interface Command
      Overrides:
      getHelp in class AbstractCommand
      Returns:
      the help text of the command, empty when the command does not define one
    • doExecute

      public ExitStatus doExecute(CommandContext commandContext) throws Exception
      Specified by:
      doExecute in class AbstractCommand
      Throws:
      Exception