User Tools

Site Tools


documentation:script

What is Typescript?

Typescript is a program that captures and saves your terminal session in to a text file.

How do I use it?

To start capturing your terminal session you need to start you typescript session; that can be done by typing “script”:

lab46:~$ script
Script started, file is typescript
lab46:~$ 

Now go and perform the actions you wish to have output captured. Please avoid using backspaces, the arrow keys, and programs that try to manage the screen (like nano, vi, pine). This is meant for simple command-line operations only… anything else will result in less readable results.

When you are finished, simply type exit, in the same session you are scripting:

lab46:~$ exit
exit
Script done, file is typescript
lab46:~$ 

There will be a file, typescript, in your directory, which will contain a text-based account of what just transpired in your session.

If you wish to retain this file and use typescript again then you will need to rename the file before you can use typescript again other wise the file data will be lost.

lab46:~$ mv typescript NewFileName
lab46:~$

This will mv the file typescript to a new file name.

For more information

For more informative on typescript on type “man script” to read the manual page.

There are some options you can provide to change its behavior, including having it create a different file instead of “typescript”.

documentation/script.txt · Last modified: 2010/12/11 02:51 by jbrant