[Next] [Up] [Previous] [Contents]
Next: telnet Up: Additional commands Previous: spell

tar

The tar (tape archiver) program is useful for storing a bunch of files in one file (usually on a magnetic tape, but it doesn't have to be). The syntax for this command is


    tar [key] [name ...]
where key is specified by a plethora of options (see abridged list below and unabridged list in the man pages) and name is either the file name or device name.

Here are some of the more commonly used keys:


    c    Creates a new tape.
    f    Used for taring to a tape.
    t    Lists the contents of a tar file.
    v    Turns verbose on.
    x    Extracts selected files.  If no file argument is given,
         the entire contents of the tar file is extracted.
Here is the syntax I use to create and read tar files:


    tar cvf /dev/drivename directoryname   <-- creates
    tar xvf /dev/drivename directoryname   <-- reads

c.c.taylor@ieee.org