Forrest logo
back to the history tool

history:tldr:3cd15

history: Display the commands history list with line numbers.
$ history
try on your machine

The command "history" is a built-in command in most Unix-like operating systems. When executed, it displays a list of previously executed commands in the terminal session, also known as the command history.

The output of the "history" command generally includes the line number of each command, followed by the actual command entered. The most recent commands are usually displayed at the bottom of the list.

This command is useful for recalling and reusing previous commands. By referencing the line number of a specific command from the history, you can execute it again without having to retype it entirely. Additionally, the history command can be combined with other commands and features to perform various actions like filtering, searching, or manipulating the command history.

It's important to note that the command history may not be available in all terminal emulators or command-line interfaces. Additionally, the number of commands stored in the history, as well as the location of the history file, can be configured in the shell settings and may vary depending on the system configuration.

This explanation was created by an AI. In most cases those are correct. But please always be careful and never run a command you are not sure if it is safe.
back to the history tool