Forrest logo
back to the script tool

script:tldr:999cd

script: Execute quietly without start and done messages.
$ script -q ${logfile-log}
try on your machine

The command "script -q ${logfile-log}" executes the "script" command with the "-q" flag and a specified log file.

The "script" command is used to create a typescript of a terminal session. It captures all the input and output, including the command prompts, text output, and any error messages. By default, the output is saved in a file called "typescript".

The "-q" flag stands for "quiet" and is used to suppress the messages that are normally displayed when starting and ending the script.

In this command, "${logfile-log}" is a variable that represents the name of the log file. It is enclosed in braces "${}" for substitution. The "-log" portion is appended to the log file name, so the actual log file name will depend on the value of the "logfile" variable.

Overall, the command "script -q ${logfile-log}" runs the "script" command to log a terminal session to a specific log file, suppressing any system messages.

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 script tool