File: unzip_def.rnh

package info (click to toggle)
unzip 5.40-1
  • links: PTS
  • area: non-free
  • in suites: potato
  • size: 4,120 kB
  • ctags: 5,900
  • sloc: ansic: 40,977; cpp: 3,778; makefile: 1,384; asm: 1,228; sh: 133
file content (278 lines) | stat: -rw-r--r-- 11,535 bytes parent folder | download
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
.!
.!  File:       UNZIP_DEF.RNH
.!
.!  Author:     Hunter Goatley
.!
.!  Date:       October 23, 1991
.!
.!  Description:
.!
.!      RUNOFF source file for VMS on-line help for portable UnZip.
.!      Adapted from UNZIP.MAN (now UNZIP.DOC).
.!
.!      To build:       $ REN UNZIP_DEF.RNH UNZIP.RNH
.!                      $ RUNOFF UNZIP.RNH
.!                      $ LIBR/HELP/INSERT libr UNZIP
.!
.!  Modification history:
.!
.!      01-001          Hunter Goatley          23-OCT-1991 09:21
.!              Genesis.
.!      01-002          Cave Newt               16-MAR-1992 22:37
.!              Updated for UnZip 4.2.
.!      01-003          Igor Mandrichenko       23-MAY-1992 22:14
.!              Added -X option to command syntax.
.!      01-004          Cave Newt               24-MAY-1992 13:30
.!              Added UNZIP_OPTS environment variable help.
.!      01-005          Igor Mandrichenko       14-DEC-1993 18:55
.!              Modified for UnZip V5.1
.!      01-006          Cave Newt               21-DEC-1993 12:38
.!              Added -x option and cleaned up.
.!      01-007          Cave Newt               14-JUL-1994 09:45
.!              Added -Z, -C and -L options, removed -U, minor clean-up.
.!      01-008          Cave Newt               28-JUL-1994 08:57
.!              Removed semi-colons from comments.
.!      02-001          Christian Spieler       09-DEC-1995 02:25
.!              Modified for UnZip 5.2.
.!      02-002          Christian Spieler       06-FEB-1996 02:25
.!              Added -h "help" option.
.!      02-003          Christian Spieler       04-MAR-1997 20:25
.!              Added -P "command line password" option.
.!      02-004          Christian Spieler       26-JUL-1997 00:05
.!              Added Exit_Codes subtopic, explaining UnZip's VMS return codes.
.!
.noflags
.lm4 .rm72
.indent -4
1 UNZIP
.br
UnZip is used to extract files compressed and packaged by Zip (see HELP ZIP
for information on ZIP).
.sk
For a brief help on Zip and Unzip, run each without specifying any
parameters on the command line, or specify the -h flag (but not in UnZip's
Zipinfo mode).
.sk
UNZIP will list, test, or extract from a ZIP archive.  ZIP archives are commonly
found on MS-DOS systems; a VMS version of ZIP can also be found here.
.sk
Archive member extraction is implied by the absence of the -c, -p, -t, -l, -v or
-z options.  All archive members are processed unless a filespec is provided to
specify a subset of the archive members.
Format:
.sk;.lm+1;.literal
UNZIP [-cfhlptuvxz[ajnoqCLMVX]] file[.zip] [list] [-x xlist] [-d out_dir]
.end literal;.lm-1
.!------------------------------------------------------------------------------
.indent -4
2 Parameters
.sk;.indent -4
file[.zip]
.sk
File specification for the ZIP archive(s) with optional wildcards. UnZip will
perform actions specified for every zipfile matching the specification.
Default file specification is SYS$DISK:[].ZIP.
Note that self-extracting ZIP files are supported; just specify the .EXE
suffix yourself.
.sk;.indent -4
[list]
.sk
An optional list of archive members to be processed; if no list is given, all
archive members are processed.  Expressions may be
used to match multiple members.  Expressions should be enclosed in double-quotes
to prevent interpretation by DCL.  Multiple filenames should be separated by
blanks.  Each file specification is similar to a Unix egrep expression and may
contain:
.sk
.literal
     *       matches a sequence of 0 or more characters
     ?       matches exactly 1 character
     [...]   matches any single character found inside the brackets;
             ranges are specified by a beginning character,
             a hyphen, and an ending character.  If a '!' or '^'
             immediately follows the left bracket, then any character
             not in the given range is matched.
.end literal
.sk
.sk;.indent -4
[-x xlist]
.sk
An optional list of archive members to be excluded from processing.  The xlist
overrides any files included in the normal list.
.sk;.indent -4
[-d out_dir]
.sk
Optional directory specification to be used as target root directory
for files to be extracted.  Directory should be specified in "[.foo]"
format rather than "foo.dir" or "foo/" format.
.!------------------------------------------------------------------------------
.indent -4
2 Options
.br
The default action of UnZip is to extract all zipfile entries.  The following
options and modifiers can be provided:
.sk;.literal
   -Z   ZipInfo mode
   -c   extract files to SYS$OUTPUT (terminal)
   -f   freshen existing files (replace if newer); create none
   -h   show brief help screen and exit quietly
   -l   list archive files (short format)
   -p   extract files to SYS$OUTPUT; no informational messages
   -t   test archive files
   -u   update existing files; create new ones if needed
   -v   list archive files (verbose format)
   -z   display only the archive comment
.end literal;.sk;.literal
 MODIFIERS
   -a   extract text files in standard VMS text file format
   -aa  extract all files as text
   -b   auto-extract only binary files in VMS fixed 512-byte record format
   -bb  extract all files as binary in VMS fixed 512-byte record format
   -j   junk paths (don't recreate archive's directory structure)
   -n   never overwrite existing files; don't prompt
   -o   OK to overwrite files without prompting
   -q   perform operations quietly (-qq => even quieter)
   -C   match filenames case-insensitively
   -L   convert filenames to lowercase if created under DOS, VMS, etc.
   -M   feed screen output through built-in "more" pager
   -P<password> supply decryption password on the command line (insecure!)
   -V   retain (VMS) file version numbers
   -X   restore owner/protection info (may require privileges)
.end literal;.sk
Note that uppercase options (-C, -L, -M, -P, -V and -X) must be specified
in quotes. For example:
.sk;.literal
    unzip "-VX" -a zipfile
.end literal;.sk
The output conversion options -b and -a may be combined to perform
binary conversions on binary files and text conversion on text files.
But note: For compatibility with implementation on other systems, -b cancels
any -a option; to get the intended result, -a must be specified AFTER -b.
And, in combination, "text" recognition takes precedence; this means
that -bb has the same effect as -b, and -aa overrides binary conversion
for ALL files.
.sk
Please note that using the "-P<password>" option is higly insecure, the
plaintext password may be seen by others. For this reason (and because of
lack of space), the "-P<password>" option is not advertised on UnZip's
online help screen.
.!------------------------------------------------------------------------------
.indent -4
2 Exit_Codes
.br
On VMS, UnZip's UNIX style exit values are mapped into proper
VMS status codes:
.sk;.literal
   1                               (success)  normal exit,
   (0x7fff0000 + 16*UnZip_errnum)  -W- warnings
   (0x7fff0002 + 16*UnZip_errnum)  -E- normal errors
   (0x7fff0004 + 16*UnZip_errnum)  -F- fatal errors
.end literal;.sk
The UnZip error level (or exit code) approximates the exit
codes defined by PKWARE and takes on the following values:
.sk;.literal
  VMS       UnZip    Type of error
  severity  errcode
    -         0      normal; no errors or warnings detected.

    W         1      one or more warning errors were encountered,
                     but processing completed  successfully  any-
                     way.   This  includes  zipfiles where one or
                     more files was skipped  due  to  unsupported
                     compression  method  or  encryption  with an
                     unknown password.

    E         2      a generic error in the  zipfile  format  was
                     detected.   Processing  may  have  completed
                     successfully anyway;  some  broken  zipfiles
                     created by other archivers have simple work-
                     arounds.

    F         3      a severe error in  the  zipfile  format  was
                     detected.   Processing probably failed imme-
                     diately.

    F         4      unzip was unable to allocate memory for  one
                     or  more  buffers during program initializa-
                     tion.

    F         5      unzip  was  unable  to  allocate  memory  or
                     unable  to  obtain a tty to read the decryp-
                     tion password(s).

    F         6      unzip was unable to allocate  memory  during
                     decompression to disk.

    F         7      unzip  was  unable to allocate memory during
                     in-memory decompression.

    F         8      [currently not used]

    E         9      the specified zipfiles were not found.

    E         10     invalid options were specified on  the  com-
                     mand line.

    E         11     no matching files were found.

    F         50     the disk is (or was) full during extraction.

    F         51     the end of the ZIP archive  was  encountered
                     prematurely.

    E         80     the user aborted unzip prematurely with con-
                     trol-C (or similar)

    E         81     no files were found due to unsupported  com-
                     pression  methods or unsupported decryption.
                     (If even one additional file is successfully
                     processed, however, the exit status is 1.)

    E         82     no  files  were  found due to bad decryption
                     password(s).  This is also the  exit  status
                     if  no files were found due to a combination
                     of unsupported  compression  and  bad  pass-
                     words.   As in the previous case, however, a
                     single successful file  will  result  in  an
                     exit status of 1 instead.)
.end literal;.sk
In addition, there is a compilation option to expand upon this behavior:
An executable compiled with the option RETURN_CODES defined displays
a human-readable explanation of what the error status means.
.!------------------------------------------------------------------------------
.indent -4
2 Logical_Names
.br
UnZip allows to modify its default behaviour by specifying option defaults
via the UNZIP_OPTS logical name.
For example, the following will cause UnZip to restore owner/protection
information and perform all operations at quiet-level 1 by default:
.sk;.literal
    define UNZIP_OPTS "-qX"
.end literal;.sk
Note that the quotation marks here are required to preserve lowercase options
(opposite of the command-line behavior).
To negate a default option on the command line, add one or more minus
signs before the option letter, in addition to the leading switch character
`-':
.sk;.literal
    unzip --ql zipfile
.end literal
or
.literal
    unzip -l-q zipfile
.end literal;.sk
At present it is not possible to decrement an option below zero--that is,
more than a few minuses have no effect.
.sk
UNZIP_OPTS may be defined as a symbol rather than a logical name, but if
both are defined, the logical name takes precedence.
.!-----------------------------------------------------------------------------
.indent -4
2 Authors
.br
Info-ZIP; currently maintained by Greg Roelofs.  VMS support maintained
by Christian Spieler and Hunter Goatley.  Originally based on a program
by Samuel H. Smith.
.sk
VMS on-line help ported from UNZIP.DOC by Hunter Goatley.