1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279
|
.TH Z 1 2.7.3
.SH NAME
comprez \- safely (un)tar and (de)feather files and directories
.SH SYNOPSIS
.B comprez
[
.B \-t
|
.B \-T
] [
.B \-v
|
.B \-V
] [
.B \-l
|
.B \-L
] [
.B \-gz
|
.B \-z
|
.B \-I
|
.B \-lz
|
.B \-xz
|
.B \-Z
|
.B \-zip
|
.B \-jar
] [
.B \-#
] [
.B \-s
.I suffix
] [
.B \-m
.I mode
] [
.B \-p
|
.B \-P
] [
.B \-h
] [
.B \-\-
]
.I file ...
.SH DESCRIPTION
.I Comprez
is a simple, safe and convenient front-end for the
.IR compress (1),
.IR uncompress (1),
.IR gzip (1),
.IR bzip2 (1),
.IR lzip (1),
.IR xz (1),
.IR tar (1),
.IR zip (1)
and
.IR unzip (1)
utilities for compressing and uncompressing files and directories.
It processes each of its arguments according to the type of the
file or directory given:
.PP
If the argument is a plain file, then the file is compressed,
ie, feathered.
.PP
If the argument is a compressed file
with a name ending in \fB.Z\fP, \fB.gz\fP, \fB.z\fP, \fB.bz2\fP,
\fB.lz\fP, \fB.xz\fP, \fB.zip\fP or \fB.jar\fP,
then the file is uncompressed,
ie, defeathered.
.PP
If the argument is a directory,
then the directory is archived into one tar or zip file
which is then compressed,
ie, tarred and feathered.
.PP
If the argument is a compressed tar or zip archive
with a name ending in \fB.{tar.,tar,ta,t}{Z,gz,z,bz2,lz,xz}\fP or
\fB.{zip,jar}\fP, then the archive is uncompressed and untarred,
ie, untarred and defeathered.
.PP
The new compressed or uncompressed version will be in the same
directory as the original.
A compressed file is always uncompressed into a file with the
same name sans the feather suffix.
A compressed tar or zip archive is always unpacked into a subdirectory
with the same name as the archive sans the tar and feather suffix,
even if the archive did not itself contain such a subdirectory.
.SH OPTIONS
.PP
.TP 10
\-\-
Interprets all following arguments as files instead of options.
.TP 10
\-#
Where \fB#\fP is a digit from 1 through 9.
This option is passed on to
.IR gzip (1),
.IR bzip2 (1),
.IR lzip (1),
.IR xz (1)
and
.IR zip (1)
when feathering with them.
\fB\-\-fast\fP may be used instead of \fB\-1\fP and
\fB\-\-best\fP instead of \fB\-9\fP.
.TP 10
\-gz
Uses
.IR gzip (1)
and a \fB.gz\fP compression suffix when feathering.
Default.
.TP 10
\-h
Prints a helpful usage message.
.TP 10
\-I
Uses
.IR bzip2 (1)
and a \fB.bz2\fP compression suffix when feathering.
.TP 10
\-l
Lists the file or directory name created resulting from each argument.
.TP 10
\-L
Does not report created files or directories.
Default.
.TP 10
\-lz
Uses
.IR lzip (1)
and a \fB.lz\fP compression suffix when feathering.
.TP 10
\-xz
Uses
.IR xz (1)
and a \fB.xz\fP compression suffix when feathering.
.TP 10
\-m mode
Apply the given
.IR chmod (1)
mode argument to any created tar and feather files.
Before this argument is applied,
the files have the same read and write permissions
as the directories from which they were created.
For security, the default argument is \fBgo\-rwx\fP.
If the mode is \fB\-\fP, then no argument is applied.
See
.IR chmod (1)
for all other allowable formats of this argument.
.TP 10
\-p
Preserves modes when untarring by giving the \fBp\fP flag to
.IR tar (1).
Default.
.TP 10
\-P
Doesn't preserve modes when untarring by not giving the \fBp\fP flag to
.IR tar (1).
This option may be necessary on systems where ordinary users are
allowed to run
.IR chown (2).
.TP 10
\-s suffix
Creates tar and feather files using the given suffix style.
The default suffix style is \fB.tgz\fP.
Note that the suffix style does not dictate the program used
for feathering nor the compression suffix.
.TP 10
\-t
Only lists the table of contents of the given files.
Does not make any changes.
.TP 10
\-T
(Un)tars and (de)feathers the given files according to their type.
Default.
.TP 10
\-v
Verbose output.
For example, reports compression ratios when feathering.
.TP 10
\-V
Non-verbose output.
Does not report compression ratios.
Default.
\fB\-q\fP is a synonym.
.TP 10
\-z
Uses
.IR gzip (1)
and a \fB.z\fP compression suffix when feathering.
.TP 10
\-Z
Uses
.IR compress (1)
and a \fB.Z\fP compression suffix when feathering.
.TP 10
\-zip, \-jar
Uses
.IR zip (1)
and a \fB.zip\fP or \fB.jar\fP compression suffix
when tarring and/or feathering.
The zip format combines tarring and feathering.
\fBWARNING:\fP zip does not preserve complete Unix filesystem information
for the files it archives, such as links, some permissions, etc.
A
.IR tar (1)-based
format should be used if this is required.
.SH "ENVIRONMENT VARIABLES"
.PP
.TP 10
ZOPTS
This variable may be set to a string of the above options to
supersede the default settings.
They may still be overridden by options given on the command line.
.PP
.TP 10
GZIP
This environment variable for
.IR gzip (1)
is \fBnot\fP passed on by
.I comprez
so that
.IR gzip 's
behavior is standard and predictable.
.PP
.TP 10
ZIPOPT, UNZIP
These environment variables for
.IR zip (1)
and
.IR unzip (1)
are \fBnot\fP passed on by
.I z
so that their behavior is standard and predictable.
.SH BUGS
There should be an option to allow the use of another directory
for temporary files needed during the
(un)tarring and (de)feathering processes.
This would make
.I comprez
more useful when the quota or disk is nearly full.
.PP
There should be \fB\-k\fP and \fB\-K\fP options
for keeping the original input files or not.
.SH CAVEATS
.I Comprez
is written to work with
.I gzip
versions 1.2.3 and 1.2.4,
.I bzip2
versions 0.9.0 and 1.0.0,
Unix
.I zip
version 2.0.1 and Unix
.I unzip
version 5.12.
Other versions will probably work safely, too,
but should still be checked for compatibility.
.PP
Every effort has been made to assure that the use of this program
will not lead to the inappropriate deletion or corruption of any files.
However, there are never any guarantees,
so please use at your own risk.
.SH VERSION
2.7.3
.SH AUTHOR
Steve Kinzler, steve@kinzler.com, May 89/Jun 93/Aug 99/Dec 00
.SH URL
http://kinzler.com/me/z
.SH "SEE ALSO"
compress(1), uncompress(1), gzip(1), bzip2(1), lzip(1), xz(1), tar(1), zip(1),
unzip(1)
|