2015-02-08 22:16:27 +00:00
|
|
|
.Dd February 8, 2015
|
2015-01-31 13:20:02 +00:00
|
|
|
.Dt TAR 1
|
2015-01-31 19:37:03 +00:00
|
|
|
.Os sbase
|
2015-01-31 13:05:23 +00:00
|
|
|
.Sh NAME
|
|
|
|
.Nm tar
|
|
|
|
.Nd create, list or extract a tape archive
|
|
|
|
.Sh SYNOPSIS
|
|
|
|
.Nm
|
|
|
|
.Op Fl C Ar dir
|
2015-02-08 22:16:27 +00:00
|
|
|
.Op Fl j | Fl z
|
|
|
|
.Fl x Op Fl m | Fl t
|
|
|
|
.Op Fl f Ar file
|
2015-01-31 13:05:23 +00:00
|
|
|
.Nm
|
|
|
|
.Op Fl C Ar dir
|
2015-02-08 22:16:27 +00:00
|
|
|
.Op Fl j | Fl z
|
2015-01-31 13:05:23 +00:00
|
|
|
.Fl c Ar dir
|
2015-02-08 22:16:27 +00:00
|
|
|
.Op Fl f Ar file
|
2015-01-31 13:05:23 +00:00
|
|
|
.Nm
|
|
|
|
.Op Fl C Ar dir
|
2015-02-08 22:16:27 +00:00
|
|
|
.Op Fl j | Fl z
|
2015-01-31 13:05:23 +00:00
|
|
|
.Fl cf
|
2015-02-08 22:16:27 +00:00
|
|
|
.Ar file Ar dir
|
2015-01-31 13:05:23 +00:00
|
|
|
.Sh DESCRIPTION
|
|
|
|
.Nm
|
2015-02-08 22:16:27 +00:00
|
|
|
is the standard file archiver.
|
2015-01-31 13:05:23 +00:00
|
|
|
.Sh OPTIONS
|
|
|
|
.Bl -tag -width Ds
|
|
|
|
.It Fl c Ar path
|
2015-02-08 22:16:27 +00:00
|
|
|
Create archive from
|
2015-01-31 13:05:23 +00:00
|
|
|
.Ar path .
|
|
|
|
.It Fl C Ar dir
|
|
|
|
Change directory to
|
|
|
|
.Ar dir
|
|
|
|
before beginning.
|
2015-02-08 22:16:27 +00:00
|
|
|
.It Fl f Ar file
|
|
|
|
Set
|
|
|
|
.Ar file
|
|
|
|
as input | output archive instead of stdin | stdout.
|
2015-01-31 13:05:23 +00:00
|
|
|
.It Fl m
|
|
|
|
Do not preserve modification time.
|
|
|
|
.It Fl t
|
2015-02-08 22:16:27 +00:00
|
|
|
List all files in the archive.
|
2015-01-31 13:05:23 +00:00
|
|
|
.It Fl x
|
2015-02-08 22:16:27 +00:00
|
|
|
Extract archive.
|
|
|
|
.It Fl j | Fl z
|
|
|
|
Use bzip2 | gzip compression. The
|
|
|
|
.Xr bzip2 1 |
|
2015-01-31 13:05:23 +00:00
|
|
|
.Xr gzip 1
|
2015-02-08 22:16:27 +00:00
|
|
|
utilities must be installed separately.
|
|
|
|
Using these flags is discouraged in favour of the flexibility
|
|
|
|
and clarity of pipes:
|
|
|
|
.Bd -literal -offset indent
|
|
|
|
$ bzcat archive.tar.bz2 | tar -x
|
|
|
|
$ zcat archive.tar.gz | tar -x
|
|
|
|
.Ed
|
|
|
|
.Bd -literal -offset indent
|
|
|
|
$ tar -c file ... | bzip2 > archive.tar.bz2
|
|
|
|
$ tar -c file ... | gzip2 > archive.tar.gz
|
|
|
|
.Ed
|
2015-01-31 13:05:23 +00:00
|
|
|
.El
|
|
|
|
.Sh SEE ALSO
|
|
|
|
.Xr ar 1 ,
|
|
|
|
.Xr bzip2 1 ,
|
|
|
|
.Xr gzip 1
|
2015-02-08 22:16:27 +00:00
|
|
|
.Sh STANDARDS
|
|
|
|
The
|
|
|
|
.Nm
|
|
|
|
utility is compliant with the UStar (Uniform Standard Tape ARchive)
|
|
|
|
format defined in the
|
|
|
|
.St -p1003.1-88
|
|
|
|
specification.
|