<h3>NAME</h3><p>script - make typescript of terminal session </p><h3>SYNOPSIS</h3><p><strong>script</strong> [-<strong>a</strong> ] [-<strong>f</strong> ] [-<strong>q</strong> ] [-<strong>t</strong> ] [<em>file</em> ] </p><h3>DESCRIPTION</h3><p><strong>Script</strong> makes a typescript of everything printed on your terminal. It is useful for students who need a hardcopy record of an interactive session as proof of an assignment, as the typescript file can be printed out later with <a href="https://www.lifewire.com/linux-command-lpr-4092334" data-component="link" data-source="inlineLink" data-type="internalLink" data-ordinal="1">lpr</a>(1).</p><p>If the argument <em>file</em> is given, <strong>script</strong> saves all dialogue in <em>file</em> If no <a href="https://www.lifewire.com/rename-files-using-linux-command-line-3991979" data-component="link" data-source="inlineLink" data-type="internalLink" data-ordinal="2">file name</a> is given, the typescript is saved in the file typescript</p><p>Options:</p><p><strong>-a</strong></p><p>Append the output to <em>file</em> or typescript retaining the prior contents.</p><p><strong>-f</strong></p><p>Flush output after each write. This is nice for telecooperation: One person does &#96;mkfifo foo; script -f foo&#39; and another can supervise real-time what is being done using &#96;cat foo&#39;.</p><p><strong>-q</strong></p><p>Be quiet.</p><p><strong>-t</strong></p><p>Output timeing data to standard error. This data contains two fields, separated by a space. The first field indicates how much time elapsed since the previous output. The second field indicates how many characters were output this time. This information can be used to replay typescripts with realistic typing and output delays.</p><p>The script ends when the forked shell exits (a <em>control-D</em> to exit the Bourne shell ( sh(1)) and <em>exit ,</em><em>logout</em> or <em>control-d</em> (if <em>ignoreeof</em> is not set) for the C-shell, csh(1)).</p><p>Certain interactive commands, such as vi(1), create garbage in the typescript file. <strong>Script</strong> works best with commands that do not manipulate the screen, the results are meant to emulate a hardcopy terminal. </p><p><strong>Important:</strong> Use the <em>man</em> command (<em>% man</em>) to see how a command is used on your particular computer.</p>