TAR(1)

NAME
tar - create, list or extract a tape archive

SYNOPSIS
tar x | t | -x | -t [-C dir] [-J | -Z | -a | -j | -z] [-m] [-p] [-f file] [file ...]
tar c | -c [-C dir] [-J | -Z | -a | -j | -z] [-h] path ... [-f file]

DESCRIPTION
tar is the standard file archiver.

OPTIONS

-c path ...
    Create archive from path.

-C dir
    Change directory to dir before beginning.

-f file
    Set file as input | output archive instead of stdin | stdout. If '-', stdin | stdout is used.

-m  Do not preserve modification time.

-t  List all files in the archive.

-x  Extract archive.

-h  Always dereference symbolic links while recursively traversing directories.

-J | -Z | -a | -j | -z
    Use xz | compress | lzma | bzip2 | gzip compression or decompression. These utilities must be installed separately. Using these flags is discouraged in favour of the flexibility and clarity of pipes:

        $ bzip2 -cd archive.tar.bz2 | tar -x
        $ gzip -cd archive.tar.gz | tar -x

        $ tar -c file ... | bzip2 > archive.tar.bz2
        $ tar -c file ... | gzip2 > archive.tar.gz

SEE ALSO
ar(1), bzip2(1), gzip(1)

STANDARDS
The tar utility is compliant with the UStar (Uniform Standard Tape ARchive) format defined in the p1003.1-88 specification. For long file paths (>99 bytes), the UStar, 'L' and 'x' header formats are supported for reading (to a maximum size of PATH_MAX or 255 bytes, depending on format), and the 'L' format is supported for writing (with unlimited path size). Link targets are limited to the UStar maximum of 100 bytes.