zip_cli.help 62 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474147514761477147814791480148114821483148414851486148714881489149014911492149314941495149614971498149915001501150215031504150515061507150815091510151115121513151415151516151715181519152015211522152315241525152615271528152915301531153215331534153515361537153815391540154115421543154415451546154715481549155015511552155315541555155615571558155915601561156215631564156515661567156815691570157115721573157415751576157715781579158015811582158315841585158615871588158915901591159215931594159515961597159815991600160116021603160416051606160716081609161016111612161316141615161616171618161916201621162216231624162516261627162816291630163116321633163416351636
  1. .!
  2. .! File: ZIP_CLI.HELP
  3. .!
  4. .! Author: Christian Spieler
  5. .!
  6. .! Date: 05 Dec 95 (orig. ZIP.RNH, 22 Oct 91)
  7. .!
  8. .! Description:
  9. .!
  10. .! TPU-processable source file to produce VMS on-line help for
  11. .! portable Zip. Adapted from ZIP.RNH, originally based on
  12. .! ZIP.MAN (now MANUAL).
  13. .!
  14. .! To build:
  15. .! $ EDIT /TPU/NOSECTION/NODISPLAY/COMMAND=CVTHELP.TPU ZIP_CLI.HELP
  16. .! $ RUNOFF /OUT=ZIP_CLI.HLP ZIP_CLI.RNH
  17. .! $ LIBR /HELP/INSERT libr ZIP_CLI
  18. .!
  19. .! Modification history:
  20. .!
  21. .! 01-001 Christian Spieler 05-DEC-1995 02:02
  22. .! Genesis.
  23. .! 01-002 Christian Spieler 20-JAN-1996 03:09
  24. .! Modified /LICENSE and /VERBOSE descriptions.
  25. .! 01-003 Christian Spieler 11-FEB-1996 23:09
  26. .! Added /[NO]EXTRA_FIELDS description.
  27. .! 01-004 Christian Spieler 11-MAR-1996 20:08
  28. .! Removed /ENCRYPT=VERIFY option.
  29. .! 01-005 Christian Spieler 11-MAY-1996 23:08
  30. .! Corrected/enhanced info about how to get help on UNIX options.
  31. .! 01-006 Christian Spieler 21-JUL-1997 22:26
  32. .! Updated for new options of Zip 2.2.
  33. .! 01-006 Christian Spieler 14-OCT-1997 22:04
  34. .! Cleanups for Zip 2.2 release (no version change).
  35. .! 01-007 Steven Schweda 15-MAY-2007
  36. .! Zip 3.0.
  37. .! 01-007 Ed Gordon 15-MAY-2007
  38. .! Minor updates to Zip 3.0 help.
  39. .!
  40. <INIT>
  41. <MAIN>
  42. ZIP
  43. Zip is a compression and file packaging utility for several operating
  44. systems, including UNIX, VMS, MSDOS, OS/2, Windows 9x/NT/XP, Minix,
  45. Atari, Macintosh, Amiga, and Acorn RISC OS. It is analogous to a
  46. combination of tar and compress and is compatible with PKZIP (Phil
  47. Katz's ZIP) for MSDOS systems.
  48. Zip is useful for packaging a set of files for distribution, for
  49. archiving files, and for saving disk space by temporarily compressing
  50. unused files or directories. A companion program, UnZip, unpacks Zip
  51. archives.
  52. For brief help on Zip or UnZip, run the program without specifying any
  53. parameters on the command line.
  54. This description covers the Zip program which uses a VMS-style CLI
  55. command line. The VMS CLI Zip program also accepts UNIX-style "-opt"
  56. options, but a separate Zip program is available which provides only a
  57. UNIX-style command line, and it has its own documentation. Refer to
  58. the Zip installation instructions for details.
  59. <FORMAT>
  60. ZIP [/options] archive inpath, inpath ...
  61. .!
  62. <TOPIC>
  63. Basic_Usage
  64. <FORMAT>
  65. ZIP [/options] archive inpath, inpath ...
  66. The default action of Zip is to add or replace entries in "archive" from
  67. the list of "inpath" file specifications, which can include directories
  68. and file names with VMS-style wildcards. If /BATCH is specified, Zip
  69. will read file specifications from a list file or from SYS$INPUT
  70. (stdin).
  71. With SET PROCESS /PARSE_STYLE = EXTENDED (available on recent non-VAX
  72. systems), Zip preserves the case of the command line. Otherwise, mixed-
  73. or upper-case arguments (file names) must be quoted. Examples in this
  74. document generally do not show this quotation, so VAX and /PARSE_STYLE =
  75. TRADITIONAL users (that is, troglodytes) will need to add quotation
  76. where needed when working with these examples.
  77. General
  78. Zip reads one or more files, compresses the data (normally), and stores
  79. the compressed information into a single Zip archive file, along with
  80. information about each file (name, path, date and time of last
  81. modification, protection, and check information to verify file
  82. integrity). On a VMS system, Zip can also save VMS/RMS file attributes,
  83. allowing UnZip to restore the files without loss of important file
  84. attributes. Zip can pack an entire directory structure into a Zip
  85. archive with a single command.
  86. Compression
  87. Compression ratios of 2:1 to 3:1 are common for text files. Zip has one
  88. standard compression method ("deflate") and can also store files without
  89. compression. Zip (and UnZip) may be built with optional support for the
  90. bzip2 compression method. Then, the user may select bzip2 compression
  91. instead of the default "deflate" method. Zip automatically chooses
  92. simple storage over compression for a file, if the specified compression
  93. method does not actually compress the data in that file.
  94. Compatibility
  95. Zip and UnZip can work with archives produced by PKZIP (supporting most
  96. PKZIP features up to PKZIP version 4.6), and PKZIP and PKUNZIP can work
  97. with archives produced by Zip (with some exceptions, notably streamed
  98. archives, but recent changes in the .ZIP file standard may facilitate
  99. better compatibility). Zip version 3.0 is compatible with PKZIP 2.04
  100. and also supports the Zip64 extensions of PKZIP 4.5 which allows
  101. archives as well as files to exceed the previous 2 GB limit (4 GB in
  102. some cases). Zip also supports bzip2 compression if the bzip2 library
  103. is included when Zip is built. Note that PKUNZIP 1.10 cannot extract
  104. files produced by PKZIP 2.04 or Zip 3.0. You must use PKUNZIP 2.04g or
  105. UnZip 5.0p1 (or later versions) to extract them.
  106. Large Archives and Zip64
  107. Where the operating system and C run-time support allow, Zip 3.0 and
  108. UnZip 6.0 (and later versions) support large files (input and archive),
  109. using the Zip64 extensions to the original .ZIP file format. On VMS,
  110. this genarally means non-VAX systems with VMS V7.2 or later (perhaps
  111. requiring a C RTL ECO before VMS V7.3-2).
  112. Zip automatically uses the Zip64 extensions when a file 4 GB or larger
  113. is added to an archive, an archive containing a Zip64 entry is updated
  114. (if the resulting archive still needs Zip64), the size of the archive
  115. will exceed 4 GB, or when the number of entries in the archive will
  116. exceed about 64K. Zip64 is also used for archives streamed to a
  117. non-seekable output device. You must use a 4.5 compatible UnZip to
  118. extract files using the Zip64 extensions such as UnZip 6.0 or later.
  119. In addition, streamed archives, entries encrypted with standard
  120. encryption, or split archives created with the pause option may not be
  121. compatible with PKZIP as data descriptors are used, and PKZIP at the
  122. time of this writing does not support data descriptors (but recent
  123. changes in the PKWare published .ZIP file standard now include some
  124. support for the data descriptor format Zip uses).
  125. <TOPIC>
  126. More_Usage
  127. Here is a very simple example of Zip use:
  128. <LITERAL>
  129. | zip stuff.zip *.*
  130. <LARETIL>
  131. This will create the Zip archive "stuff.zip" (assuming it does not
  132. already exist) and put all the (non-directory) files (";0") from the
  133. current default directory into "stuff.zip" in a compressed form. The
  134. archive is opened using a default file specification of
  135. "SYS$DISK:[].zip", so specifying "stuff" as the archive name would also
  136. create (or use an existing) "stuff.zip", but specifying "stuff.other"
  137. would give you that name. In general, Zip doesn't care about the type
  138. in the file specification, but for split archives (archives split over
  139. multiple files), the user should normally specify a type-less name,
  140. because Zip will normally generate sequentially numbered types ".z01",
  141. ".z02", and so on for the early splits, and then the required ".zip" for
  142. the last split. These file types are required by the Zip standard for
  143. split archives.
  144. Standard VMS wildcard expansion ($SEARCH) is used to interpret the
  145. "inpath" file and directory specifications, like the "*.*" in this
  146. example.
  147. On VMS, the most natural way to archive an entire directory tree is to
  148. use a directory-depth wildcard ("[...]"). For example:
  149. <LITERAL>
  150. | zip foo [...]*.*
  151. <LARETIL>
  152. This will create the file "foo.zip" containing all the files (";0") and
  153. directories in and below the current default directory. A more
  154. UNIX-like way to do this would be to use the /RECURSE option:
  155. <LITERAL>
  156. | zip /recurse foo *.*
  157. <LARETIL>
  158. Zip avoids including its own output files when selecting files to
  159. include in the archive, so it should be safe, as in this case, to create
  160. the archive in the same drectory as the input files.
  161. One or more specific files, directories, or subdirectories may also be
  162. specified:
  163. <LITERAL>
  164. | zip foo.zip readme.txt, [www...]*.*, [.ftp...]*.*, -
  165. | [.src]*.h, [.src]*.c
  166. <LARETIL>
  167. For security reasons, paths in Zip archives are always stored as
  168. relative paths, so some care is needed when creating an archive so that
  169. it will create the intended directory structure when UnZip is used to
  170. unpack it.
  171. To use /RECURSE with a specific directory, the name of the directory
  172. file itself must be specified:
  173. <LITERAL>
  174. | zip /recurse foo.zip [000000]www.dir, ftp.dir
  175. <LARETIL>
  176. You may want to make an archive that contains the files in [.foo], but
  177. not record the directory name, "foo". You can use the /JUNK (junk path)
  178. option to leave off the path:
  179. <LITERAL>
  180. | zip /junk foo [.foo]*.*
  181. <LARETIL>
  182. If you are short on disk space, you might not have enough room to hold
  183. both the original directory and the corresponding compressed Zip
  184. archive. In this case, you can create the archive in steps, and use the
  185. -m option. For example, if [.foo] contains the subdirectories [.tom],
  186. [.dick], and [.harry], you could:
  187. <LITERAL>
  188. | zip /move foo [.foo.tom...]*.*
  189. | zip /move foo [.foo.dick...]*.*
  190. | zip /move foo [.foo.harry...]*.*
  191. <LARETIL>
  192. The first command would create foo.zip, and the next two would add to
  193. it. The /MOVE option will cause Zip to delete all files added to the
  194. archive after making or updating foo.zip. No deletions will be done
  195. until the Zip operation has completed with no errors. This option is
  196. obviously dangerous and should be used with care, but it does reduce the
  197. need for free disk space. When /MOVE is used, the /TEST option is
  198. recommended and will test the resulting archive before deleting the
  199. input files.
  200. If a file specification list is too long to fit conveniently on the Zip
  201. command line, the /BATCH option can be used to cause Zip to read a list
  202. of file specifications from a file or from SYS$INPUT (stdin). If a DCL
  203. command procedure is used, the names can be specified in the procedure:
  204. <LITERAL>
  205. | $ zip foo /batch
  206. | $ deck
  207. | file_spec_1
  208. | file_spec_2
  209. | file_spec_3
  210. | $ eod
  211. <LARETIL>
  212. The file specifications can also be put into a separate file, and fed
  213. into Zip by specifying that file as "/BATCH = list_file", or by
  214. explicitly defining SYS$INPUT, or by using PIPE. For example, with the
  215. list in foo.zfl:
  216. <LITERAL>
  217. | zip foo /batch = foo.zfl
  218. <LARETIL>
  219. or:
  220. <LITERAL>
  221. | define /user_mode sys$input foo.zfl
  222. | zip foo /batch
  223. <LARETIL>
  224. or:
  225. <LITERAL>
  226. | pipe type foo.zfl | zip foo /batch
  227. <LARETIL>
  228. If Zip is not able to read a file, it issues a warning but continues.
  229. See the /MUST_MATCH option for more on how Zip handles patterns that are
  230. not matched and files that are not readable. If some files were
  231. skipped, a warning is issued at the end of the Zip operation noting how
  232. many files were read and how many skipped.
  233. <TOPIC>
  234. Environment
  235. A user can specify default command-line options and arguments by
  236. defining an "environment variable" (that is, a logical name or DCL
  237. symbol), "ZIP_OPTS" or "ZIPOPT", to specify them. If both "ZIP_OPTS"
  238. and "ZIPOPT" are specified, the definition of "ZIPOPT" prevails.
  239. UNIX-style command-line options are required in these variables, even
  240. for the VMS CLI Zip program. For details, see the help topic
  241. UNIX_Options, or the separate Zip help for the UNIX-style command line.
  242. The C RTL function getenv() is used to sense these variables, so its
  243. behavior determines what happens if both a logical name and a symbol are
  244. defined. As of VMS V7.3, a logical name supercedes a symbol.
  245. The "zip /VERBOSE" report should show the perceived settings of these
  246. variables.
  247. For example, the following will cause Zip to skip directories, include
  248. VMS portable attribute information, and perform all operations at
  249. quiet-level 1 by default:
  250. <LITERAL>
  251. | $ define ZIP_OPTS "-qDV"
  252. <LARETIL>
  253. Note that the quotation marks here are required to preserve lowercase
  254. options (opposite of the command-line behavior).
  255. <TOPIC>
  256. Exit_Status
  257. On VMS, Zip's UNIX-style exit values are mapped into VMS-style status
  258. codes with facility code 1955 = %x7A3, and with the inhibit-message
  259. (%x10000000) and facility-specific (%x00008000) bits set:
  260. <LITERAL>
  261. | %x17A38001 normal exit
  262. | %x17A38000+ 16* Zip_error_code warnings
  263. | %x17A38002+ 16* Zip_error_code normal errors
  264. | %x17A38004+ 16* Zip_error_code fatal errors
  265. <LARETIL>
  266. Note that multiplying the UNIX-style Zip error code by 16 places it
  267. conveniently in the hexadecimal representation of the VMS exit code,
  268. "__" in %x17A38__s, where "s" is the severity code. For example, a
  269. truncated archive might cause Zip error code 2, which would be
  270. transformed into the VMS exit status %x17A38024.
  271. The Zip VMS exit codes include severity values which approximate those
  272. defined by PKWARE, as shown in the following table:
  273. <LITERAL0>
  274. | VMS Zip err
  275. |severity code Error description
  276. |---------+---------+----------------------------------------------
  277. |Success 0 (OK) Normal; no errors or warnings detected.
  278. |Fatal 2 (EOF) Unexpected end of archive.
  279. |Error 3 (FORM) A generic error in the archive format
  280. | was detected. Processing may have completed
  281. | successfully anyway; some broken archives
  282. | created by other archivers have simple work-
  283. | arounds.
  284. |Fatal 4 (MEM) Zip was unable to allocate memory for
  285. | one or more buffers during program initializ-
  286. | ation.
  287. |Fatal 5 (LOGIC) A severe error in the archive format
  288. | was detected. Processing probably failed
  289. | immediately.
  290. |Error 6 (BIG) Entry too large to split, read, or
  291. | write.
  292. |Error 7 (NOTE) Invalid comment format.
  293. |Fatal 8 (TEST) Zip -T failed or out of memory.
  294. |Error 9 (ABORT) The user aborted zip prematurely
  295. | with control-C (or equivalent).
  296. |Fatal 10 (TEMP) Zip encountered an error while using
  297. | a tempfile.
  298. |Fatal 11 (READ) Read or seek error.
  299. |Warning 12 (NONE) Zip has nothing to do.
  300. |Error 13 (NAME) Missing or empty zip file.
  301. |Fatal 14 (WRITE) Error writing to a file.
  302. |Fatal 15 (CREAT) Zip was unable to create a file to
  303. | write to.
  304. |Error 16 (PARMS) Bad command line parameters.
  305. |Error 18 (OPEN) Zip could not open a specified file
  306. | to read.
  307. |Fatal 19 (COMPERR) Zip was built with options not
  308. | supported on this system.
  309. |Fatal 20 (ZIP64) Attempt to read unsupported Zip64
  310. | archive.
  311. <0LARETIL>
  312. <TOPIC>
  313. File_Names
  314. Zip deals with file names in the system file system and with file names
  315. in Zip archives. File names in a Zip archive are stored in a UNIX-like
  316. path-name format. For example, a VMS file specification like this:
  317. <LITERAL>
  318. [.zip30.vms]descrip.mms
  319. <LARETIL>
  320. could appear in a Zip archive as:
  321. <LITERAL>
  322. zip30/vms/descrip.mms
  323. <LARETIL>
  324. For security reasons, paths in Zip archives are always stored as
  325. relative paths, so an absolute VMS directory specification will be
  326. transformed to a relative path in the archive (that is, no leading "/").
  327. For example, the following absolute directory specification would give
  328. the same archive path as the previous (relative) example:
  329. <LITERAL>
  330. [zip30.vms]descrip.mms
  331. <LARETIL>
  332. Also, device names are dropped, so the following file specification
  333. would also give the same archive path:
  334. <LITERAL>
  335. sys$sysdevice:[zip30.vms]descrip.mms
  336. <LARETIL>
  337. If an archive is intended for use with PKUNZIP under MSDOS, then the
  338. /PKZIP option should be used to attempt to adjust the names and paths to
  339. conform to MSDOS character-set and length limitations, to store only the
  340. MSDOS file attributes (just the owner:write attribute from VMS), and to
  341. mark the entry as made under MSDOS (even though it wasn't).
  342. Note that file specifications in the file system must be specified using
  343. VMS notation, but file names in an archive must be specified using the
  344. UNIX-like notation used in the archive. For example, where a BACKUP
  345. command might look like this:
  346. <LITERAL>
  347. $ back [.zip30...]*.* /excl = [...vms]*.c stuff.bck /save
  348. <LARETIL>
  349. a corresponding Zip command might look like this:
  350. <LITERAL>
  351. $ zip /exclude = "*/vms/*.c" stuff.zip [.zip30...]*.*
  352. <LARETIL>
  353. because the files to be added to the Zip archive are specified using VMS
  354. file specifications, but the /EXCLUDE option excludes names based
  355. on their archive path/file names. Options dealing with archive names
  356. include /COPY_ENTRIES, /DELETE, /EXCLUDE, /INCLUDE, and
  357. /RECURSE=FILENAMES.
  358. Note that a UNIX-like path specification must be quoted, or else the
  359. slashes ("/") will confuse the command-line interpreter, causing errors
  360. like "%CLI-W-IVQUAL, unrecognized qualifier - check validity, spelling,
  361. and placement".
  362. Note: By default, on VMS, archive name pattern matching (/COPY_ENTRIES,
  363. /DELETE, /EXCLUDE, /INCLUDE, and /RECURSE=FILENAMES) is case sensitive,
  364. even when the file system is not case sensitive (or even case
  365. preserving). This allows accurate matching of mixed-case names in an
  366. archive which may have been created on a system with a case sensitive
  367. file system, but it can involve extra effort on VMS, where it may be
  368. necessary to use unnatural case names (or the same names in multiple
  369. cases, like "*.obj *.OBJ") for this kind of pattern matching to give the
  370. desired behavior. If completely case-blind pattern matching behavior is
  371. desired, specify the /PATTERN_CASE=BLIND option.
  372. <TOPIC>
  373. Modes_of_Operation
  374. Zip supports two distinct types of command modes, external and
  375. internal. The external modes (update, grow, and freshen) read files
  376. from the file system (as well as from an existing archive) while the
  377. internal modes (delete and copy) operate exclusively on entries in an
  378. existing archive.
  379. <LITERAL>
  380. /UPDATE
  381. <LARETIL>
  382. Update existing entries and add new files. If the archive does not
  383. exist, create it. This is the default mode, so /UPDATE is optional.
  384. <LITERAL>
  385. /GROW
  386. <LARETIL>
  387. Grow (append to) the specified Zip archive, instead of creating a new
  388. one. If this operation fails, Zip attempts to restore the archive to
  389. its original state. If the restoration fails, the archive might become
  390. corrupted. This option is ignored when there's no existing archive or
  391. when at least one archive member must be updated or deleted.
  392. <LITERAL>
  393. /FRESHEN
  394. <LARETIL>
  395. Update existing entries in an existing archive. Does not add new files
  396. to the archive.
  397. <LITERAL>
  398. /DELETE
  399. <LARETIL>
  400. Delete entries from an existing archive.
  401. <LITERAL>
  402. /COPY_ENTRIES
  403. <LARETIL>
  404. Select entries in an existing archive and copy them to a new archive.
  405. Copy mode is like update mode, but entries in the existing archive are
  406. selected by command line patterns rather than files from the file system
  407. and it uses the /OUTPUT option to write the resulting archive to a new
  408. file rather than updating the existing archive, leaving the original
  409. archive unchanged.
  410. <LITERAL>
  411. /DIFFERENCE
  412. <LARETIL>
  413. Create an incremental backup-style archive, where the resulting archive
  414. will contain all new and changed files since the original archive was
  415. created. For this to work, the input file list and current directory
  416. must be the same as during the original Zip operation.
  417. For example, if the existing archive was created using
  418. <LITERAL>
  419. zip foo_full.zip [.foo...]*.*
  420. <LARETIL>
  421. from just above the foo directory, then the command (also from just
  422. above the foo directory):
  423. <LITERAL>
  424. zip /difference /output = foo_incr.zip foo_full.zip [.foo...]*.*
  425. <LARETIL>
  426. creates the archive foo_incr.zip with just the files not in foo_full.zip
  427. and the files where the size or date-time of the files does not match
  428. that in foo_full.zip. Note that in the "ZIP /DIFFERENCE" operation, the
  429. original full archive is specified as the input archive, and the /OUTPUT
  430. option is used to specify the new (incremental) output archive.
  431. <LITERAL>
  432. /FILESYNC
  433. <LARETIL>
  434. Delete entries in the archive that do not match files on the OS.
  435. Normally files already in an archive that are not updated remain
  436. in the archive unchanged. The /FILESYNC option deletes files in
  437. the archive that are not matched during the directory scan,
  438. resulting in the archive being updated having the same contents
  439. as a new archive would. If much of the archive will remain
  440. unchanged, this can be faster than creating a new archive as
  441. copying entries is faster than compressing and adding new files.
  442. Normally, when updating an archive using relative file specifications
  443. ("[]", "[.xxx]", and so on), it helps to have the same default directory
  444. as when the archive was created, but this is not a strict requirement.
  445. <TOPIC>
  446. Self_Extracting_Archives
  447. A self-extracting archive (SFX) comprises a normal Zip archive appended
  448. to a special UnZip program (such as UNZIPSFX_CLI.EXE) for the intended
  449. target system.
  450. The UnZip distribution includes a VMS command procedure,
  451. [,vms]makesfx.com, which can be used directly or adapted to create an
  452. SFX archive from a normal Zip archive.
  453. The .ZIP file format includes offsets to data structures in the archive,
  454. and these offsets are measured from the start of the archive file.
  455. Appending an archive to an UnZip SFX executable effectively moves the
  456. start of the archive file. That makes the original offsets wrong, and
  457. that will cause the UnZip SFX program to emit warning messages when it
  458. tries to unpack the archive. Zip /ADJUST_OFFSETS can be used to adjust
  459. these offsets in a self-extracting archive. For example, to adjust the
  460. offsets in foo.sfx_exe:
  461. <LITERAL>
  462. | zip /adjust_offsets foo.sfx_exe
  463. <LARETIL>
  464. Similarly, the UnZip SFX program can be removed from a self-extracting
  465. archive (and the offsets in the archive restored) using the /UNSFX
  466. option. For example:
  467. <LITERAL>
  468. | zip /unsfx foo.sfx_exe
  469. <LARETIL>
  470. Note that a self-extracting archive contains a normal Zip archive, and a
  471. normal UnZip program can be used to expand it in the normal way. You
  472. may get a warning about extra bytes at the beginning of the archive (the
  473. UnZip SFX program), but UnZip should work properly after that. This
  474. allows data in a self-extracting archive to be accessed on any system,
  475. not just the target system where its embedded UnZip SFX program runs.
  476. <TOPIC>
  477. Split_Archives
  478. Beginning with version 3.0, Zip supports split archives. A split
  479. archive is one which is divided into multiple files, usually to allow it
  480. to be stored on multiple storage media (floppy diskettes, CD-ROMs, or
  481. the like) when a single medium would be too small to contain the whole
  482. archive. (Note that split archives are not just unitary archives split
  483. into pieces, as the .ZIP file format includes offsets to data structures
  484. in the archive, and for a split archive these are based on the start of
  485. each split, not on the start of the whole archive. Concatenating the
  486. pieces will invalidate these offsets, but UnZip can usually deal with
  487. it. Zip will usually refuse to process such a spliced archive unless
  488. the /FIX = FULL option is used to fix the offsets.)
  489. For a split archive with, say, 20 split files, the files are typically
  490. named ARCHIVE.z01, ARCHIVE.z02, ..., ARCHIVE.z19, ARCHIVE.zip, where
  491. "ARCHIVE" is the archive name specified by the user on the Zip command
  492. line. Note that the last split file is the ".zip" file. In contrast,
  493. "spanned" archives are the original multi-disk archive generally
  494. requiring floppy disks and using volume labels to store disk numbers.
  495. Zip supports split archives but not spanned archives, though a procedure
  496. exists for converting split archives of the right size to spanned
  497. archives. The reverse is also true, where each file of a spanned
  498. archive can be copied in order to files with the above names to create a
  499. split archive.
  500. <QUALIFIERS>
  501. <QUALIFIER>
  502. /ADJUST_OFFSETS
  503. /ADJUST_OFFSETS
  504. Adjust internal offsets of the Zip archive members after some data
  505. (e.g. a SFX executable stub) has been prepended to the archive file.
  506. <QUALIFIER>
  507. /APPEND
  508. /APPEND
  509. /GROW
  510. Grow (append to) the specified Zip archive, instead of creating a new
  511. one. If this operation fails, Zip attempts to restore the archive to
  512. its original state. If the restoration fails, the archive might become
  513. corrupted. This option is ignored when there's no existing archive or
  514. when at least one archive member must be updated or deleted.
  515. See also /DELETE /DIFFERENCE, /FRESHEN, /UPDATE.
  516. <QUALIFIER>
  517. /BATCH
  518. /BATCH[=list_file]
  519. Read input file specifications (inpaths) from "list_file" (one per
  520. line). The list_file defaults to SYS$INPUT.
  521. <QUALIFIER>
  522. /BEFORE
  523. /BEFORE=VMS_date_time
  524. Restricts the files by date-time when adding, updating, or freshening an
  525. archive. Only files with modification date-times earlier than the
  526. specified date-time are accepted.
  527. See also /SINCE.
  528. <QUALIFIER>
  529. /COMMENTS
  530. /COMMENTS[=KEYWORD[,KEYWORD]]
  531. Add comments to the Zip archive.
  532. <LITERAL>
  533. | ARCHIVE Add/replace the multi-line archive comment. (default)
  534. | FILES Add file comment to each updated/added archive member.
  535. <LARETIL>
  536. The Zip program prompts for each comment to be added, which makes sense
  537. only if Zip is run interactively.
  538. The one-line file (archive member) comments are terminated by typing
  539. <Return>. To skip a file comment, just type <Return> without entering
  540. any further characters.
  541. The Zip archive comment may be multi-line. The comment is ended by a
  542. line containing just a period, or by an end-of-file character (CTRL/Z).
  543. <QUALIFIER>
  544. /COMPRESSION
  545. /COMPRESSION = {BZIP2|DEFLATE|STORE}
  546. Specify the compression method to be used when adding or updating files
  547. in an archive. STORE disables compression (like /LEVEL = 0). Default:
  548. /COMPRESSION = DEFLATE.
  549. Zip can archive files with or without compression. The standard
  550. compression method ("deflate") is compatible with all UnZip versions
  551. (except really old ones that only understand the "store" method).
  552. Current Zip and UnZip versions may be built with optional support for
  553. the bzip2 compression method. (The bzip2 method can compress better,
  554. especially when compressing highly redundant files, but uses more CPU
  555. time, and requires an UnZip which includes the optional bzip2 support.
  556. See the installation instructions for details on adding bzip2
  557. compression support at build time.)
  558. <QUALIFIER>
  559. /COPY_ENTRIES
  560. /COPY_ENTRIES
  561. Select entries in an existing archive and copy them to a new archive.
  562. Copy mode is like update mode, but entries in the existing archive are
  563. selected by command line patterns rather than files from the file system
  564. and it uses the /OUTPUT option to write the resulting archive to a new
  565. file rather than updating the existing archive, leaving the original
  566. archive unchanged.
  567. <QUALIFIER>
  568. /DELETE
  569. /DELETE
  570. Delete entries from archive.
  571. See also /DIFFERENCE, /FRESHEN, /GROW, /UPDATE.
  572. <QUALIFIER>
  573. /DIFFERENCE
  574. /DIFFERENCE
  575. Create an incremental backup-style archive, where the resulting archive
  576. will contain all new and changed files since the original archive was
  577. created. For this to work, the input file list and current directory
  578. must be the same as during the original Zip operation.
  579. See also /DELETE, /FRESHEN, /GROW, /UPDATE.
  580. <QUALIFIER>
  581. /DIRNAMES
  582. /DIRNAMES (default)
  583. /NODIRNAMES
  584. Store directory entries in the archive.
  585. <QUALIFIER>
  586. /DISPLAY
  587. /DISPLAY=(KEYWORD[,KEYWORD[...]])
  588. Enable display of progress messages.
  589. <LITERAL>
  590. | BYTES Running count of bytes processed and bytes to go.
  591. | COUNTS Running count of entries done and entries to go.
  592. | DOTS = size Dots every <size> MB while processing files.
  593. | (0: no dots.)
  594. | GLOBALDOTS Progress dots reflect the whole archive instead of each
  595. | file.
  596. | USIZE Uncompressed size of each entry.
  597. | VOLUME Display the volume (disk) number each entry is being
  598. | written to.
  599. <LARETIL>
  600. The default is a dot every 10 MB of input file processed. The /VERBOSE
  601. option also displays dots and used to at a higher rate than this (at the
  602. same rate as in previous versions of Zip) but this rate has been changed
  603. to the new 10 MB default, and is also controlled by /DISPLAY=DOTS=size.
  604. <QUALIFIER>
  605. /DOT_VERSION
  606. /DOT_VERSION
  607. Directs Zip to retain VMS file version numbers on names in an archive,
  608. but as ".nnn" instead of ";nnn". By default, for compatibility
  609. with non-VMS systems, Zip strips VMS file version numbers from the names
  610. stored in an archive. Thus, without /DOT_VERSION or /KEEP_VERSION, a
  611. version number wildcard (";*") can cause errors when multiple versions
  612. of a single file are treated as multiple files with the same name.
  613. See also /KEEP_VERSION.
  614. <QUALIFIER>
  615. /ENCRYPT
  616. /ENCRYPT[="password"]
  617. Encrypt new or updated archive entries using a password which is
  618. supplied by the user interactively on the terminal in response to a
  619. prompt. (The password will not be echoed.) If SYS$COMMAND is not a
  620. terminal, Zip will exit with an error. The password is verified before
  621. being accepted.
  622. You may specify the password on the command line, although we do not
  623. recommend it because THIS IS INSECURE. Remember to enclose the password
  624. string with quotation marks ("pass word"), to prevent automatic
  625. conversion to upper case or misinterpretation of punctuation characters
  626. by DCL.
  627. Because standard Zip encryption is weak, where security is truly
  628. important, use a strong encryption program, such as Pretty Good Privacy
  629. (PGP) or GNU Privacy Guard (GnuPG), on an archive instead of standard
  630. Zip encryption. A stronger encryption method, such as AES, is planned
  631. for Zip 3.1.
  632. <QUALIFIER>
  633. /EXCLUDE
  634. /EXCLUDE=(file[,...])
  635. A comma-separated list of files to exclude when deleting, updating, or
  636. adding files in the archive. If multiple files are specified, the list
  637. should be enclosed in parentheses.
  638. <QUALIFIER>
  639. /EXLIST
  640. /EXLIST=list_file
  641. The files matching the filename patterns listed in "list_file" are
  642. excluded when deleting, updating or adding files in the archive.
  643. The "list_file" is a normal text file with one filename pattern entry per
  644. line. The name pattern entries are recognized exactly as found in
  645. "list_file", including leading, embedded, and trailing whitespace or most
  646. control characters (with exception of LineFeed and probably CarriageReturn).
  647. <QUALIFIER>
  648. /EXTRA_FIELDS
  649. /EXTRA_FIELDS (default)
  650. /NOEXTRA_FIELDS
  651. Allows (or suppresses) the saving of any optional extra fields in the
  652. archive. (/NOEXTRA_FIELDS conflicts with /VMS[=ALL].)
  653. The .ZIP file format allows some extra data to be stored with a file in
  654. the archive. For example, where local time zone information is
  655. available, Zip can store UTC date-time data for files. (Look for
  656. USE_EF_UT_TIME in a "zip -v" report.) On VMS, with /VMS[=ALL], Zip will
  657. also store VMS-specific file attributes. These data are packaged as
  658. "extra fields" in the archive. Some extra fields are specific to a
  659. particular operating system (like VMS file attributes). Large files
  660. (bigger than 4GB) on any OS require an extra field to hold their 64-bit
  661. size data. Depending on the capabilities of the UnZip program used to
  662. expand the archive, these extra fields may be used or ignored when files
  663. are extracted from the archive.
  664. Some extra fields, like UTC date-times or VMS file attributes, are
  665. optional. Others, like the Zip64 extra field which holds 64-bit sizes
  666. for a large file, are required.
  667. <QUALIFIER>
  668. /FILESYNC
  669. /FILESYNC
  670. Delete entries in the archive that do not match files on the OS.
  671. Normally when an archive is updated, new files are added and changed
  672. files are updated but files that no longer exist on the OS are not
  673. deleted from the archive. This option enables deleting of entries that
  674. are not matched on the OS. Enabling this option should create archives
  675. that are the same as new archives, but since existing entries are copied
  676. instead of compressed, updating an existing archive with /FILESYNC can
  677. be much faster than creating a new archive. If few files are being
  678. copied from the old archive, it may be faster to create a new archive
  679. instead.
  680. This option deletes files from the archive. If you need to preserve the
  681. original archive, make a copy of the archive first, or use the /OUTPUT
  682. option to output the new archive to a new file. Even though it's
  683. slower, creating a new archive with a new archive name is safer, avoids
  684. mismatches between archive and OS paths, and is preferred.
  685. <QUALIFIER>
  686. /FIX_ARCHIVE
  687. /FIX=_ARCHIVE={NORMAL|FULL}
  688. The /FIX_ARCHIVE=NORMAL option (NORMAL is the default) can be used if
  689. some portions of the archive are missing, but it requires a reasonably
  690. intact central directory. The input archive is scanned as usual, but
  691. zip will ignore some problems. The resulting archive should be valid,
  692. but any inconsistent entries will be left out.
  693. If the archive is too damaged or the end (where the central directory is
  694. situated) has been truncated, you must use /FIX_ARCHIVE=FULL. This is
  695. a change from zip 2.32, where the /FIX=NORMAL option was able to read a
  696. truncated archive. The /FIX=NORMAL option now more reliably fixes
  697. archives with minor damage, and the /FIX=FULL option is needed to fix
  698. some archives where /FIX=NORMAL was sufficient before.
  699. With /FIX=FULL, the archive is scanned from the beginning and Zip scans
  700. for special signatures to identify the limits between the archive
  701. members. The /FIX=NORMAL option is more reliable if the archive is not
  702. too much damaged, so try this option first.
  703. Neither option will recover archives that have been incorrectly
  704. transferred, such as by FTP in ASCII mode instead of binary. After the
  705. repair, the /TEST (-t) option of UnZip may show that some files have a
  706. bad CRC. Such files cannot be recovered; you can remove them from the
  707. archive using the /DELETE option of Zip.
  708. Because of the uncertainty of the "fixing" process, it's required
  709. to specify an output archive, rather than risking further damage to the
  710. original damaged archive. For example, to fix the damaged archive
  711. foo.zip:
  712. <LITERAL>
  713. zip /fix_archive /output=foo_fix foo
  714. <LARETIL>
  715. tries to read the entries normally, copying good entries to the new
  716. archive foo_fix.zip. If this doesn't work, as when the archive is
  717. truncated, or if some entries are missed because of bad central
  718. directory entries, try /FIX_ARCHIVE=FULL:
  719. <LITERAL>
  720. zip /fix_archive=full /output=foo_fixfix foo
  721. <LARETIL>
  722. and compare the resulting archive to the archive created using
  723. /FIX=NORMAL. The /FIX=FULL option may create an inconsistent archive.
  724. Depending on what is damaged, you can then use the /FIX=NORMAL option to
  725. fix that archive.
  726. A split archive with missing split files can be fixed using /FIX=NORMAL
  727. if you have the last split of the archive (the ".zip" file). If this
  728. file is missing, you must use /FIX=FULL to fix the archive, which will
  729. prompt you for the splits you have.
  730. Currently, the fix options can't recover an entry which has a bad
  731. checksum or is otherwise damaged.
  732. <QUALIFIER>
  733. /FRESHEN
  734. /FRESHEN
  735. Update existing entries in an existing archive. Does not add new files
  736. to the archive.
  737. See also /DELETE, /DIFFERENCE, /GROW, /UPDATE.
  738. <QUALIFIER>
  739. /FULL_PATH
  740. /FULL_PATH (default)
  741. /NOFULL_PATH
  742. Directs Zip to store the directory part of the file names (relative to
  743. the current working directory) in the Zip archive. With /NOFULL_PATH,
  744. Zip stores only the file names, discarding any directory information.
  745. <QUALIFIER>
  746. /GROW
  747. /GROW
  748. /APPEND
  749. Grow (append to) the specified Zip archive, instead of creating a new
  750. one. If this operation fails, Zip attempts to restore the archive to
  751. its original state. If the restoration fails, the archive might become
  752. corrupted. This option is ignored when there's no existing archive or
  753. when at least one archive member must be updated or deleted.
  754. See also /DELETE, /DIFFERENCE, /FRESHEN, /UPDATE.
  755. <QUALIFIER>
  756. /HELP
  757. /HELP[=EXTENDED]
  758. Display Zip's help screen, including the version message. With
  759. /HELP=EXTENDED, more detailed (longer) help information is shown.
  760. <QUALIFIER>
  761. /INCLUDE
  762. /INCLUDE=(file[,...])
  763. A comma-separated list of files to include when deleting, updating, or
  764. adding files in the archive. If multiple files are specified, the list
  765. should be enclosed in parentheses.
  766. <QUALIFIER>
  767. /INLIST
  768. /INLIST=list_file
  769. The files matching the filename patterns listed in "list_file" are
  770. included when deleting, updating, or adding files in the archive.
  771. The "list_file" is a normal text file with one filename pattern entry per
  772. line. The name pattern entries are recognized exactly as found in
  773. "list_file", including leading, embedded, and trailing whitespace or most
  774. control characters (with exception of LineFeed and probably CarriageReturn).
  775. <QUALIFIER>
  776. /JUNK
  777. /JUNK
  778. /NOJUNK (default)
  779. Junk (discard) the directory part of the file names for added entries
  780. (do not not save the directory structure). The /JUNK qualifier is an
  781. alias for /NOFULL_PATH.
  782. <QUALIFIER>
  783. /KEEP_VERSION
  784. /KEEP_VERSION
  785. /NOKEEP_VERSION (default)
  786. Directs Zip to retain VMS file version numbers on names in an archive.
  787. By default, for compatibility with non-VMS systems, Zip strips VMS
  788. file version numbers from the names stored in an archive. Thus, without
  789. /DOT_VERSION or /KEEP_VERSION, a version number wildcard (";*") can
  790. cause errors when multiple versions of a single file are treated as
  791. multiple files with the same name.
  792. See also /DOT_VERSION.
  793. <QUALIFIER>
  794. /LATEST
  795. /LATEST
  796. The archive's creation and modification time is set to the latest
  797. modification time of all archive members.
  798. <QUALIFIER>
  799. /LEVEL
  800. /LEVEL=number
  801. Specifies the compression level:
  802. <LITERAL>
  803. | 0 Store
  804. | 1 Fastest compression (Defl:F)
  805. | ...
  806. | 9 Best compression (Defl:X)
  807. <LARETIL>
  808. The default level is 6.
  809. <QUALIFIER>
  810. /LICENSE
  811. /LICENSE
  812. Displays the Zip license.
  813. <QUALIFIER>
  814. /LOG_FILE
  815. /LOG_FILE=(FILE=log_file [, APPEND] [, INFORMATIONAL])
  816. Zip normally sends messages to the user's terminal, but these may be
  817. also directed to a log file.
  818. <LITERAL>
  819. FILE=log_file
  820. <LARETIL>
  821. Open a logfile at the given path. By default, a new version will be
  822. created.
  823. <LITERAL>
  824. APPEND
  825. <LARETIL>
  826. Append to an existing log file. Default is to create a new version.
  827. <LITERAL>
  828. INFORMATIONAL
  829. <LARETIL>
  830. Only warnings and errors are written to the log unless the INFORMATIONAL
  831. option is also specified, then all information messages are also written
  832. to the log.
  833. <QUALIFIER>
  834. /MOVE
  835. /MOVE
  836. Move the specified files into the Zip archive. That is, Zip will delete
  837. any files which are successfully added to or updated in the archive. No
  838. deletions will be done until the Zip operation has completed with no
  839. errors. This option is obviously dangerous and should be used with
  840. care, but it does reduce the need for free disk space. It's recommended
  841. that /TEST also be used to test the archive before the input files are
  842. deleted.
  843. <QUALIFIER>
  844. /MUST_MATCH
  845. /MUST_MATCH
  846. All input patterns must match at least one file and all input files
  847. found must be readable. Normally when an input pattern does not match
  848. a file the "name not matched" warning is issued and when an input
  849. file has been found but later is missing or not readable a "missing or
  850. not readable" warning is issued. In either case Zip continues
  851. creating the archive, with missing or unreadable new files being skipped
  852. and files already in the archive remaining unchanged. After the
  853. archive is created, if any files were not readable zip returns the OPEN
  854. error code (18 on most systems) instead of the normal success return (0
  855. on most systems). With /MUST_MATCH, Zip exits as soon as an input
  856. pattern is not matched (whenever the "name not matched" warning would be
  857. issued) or when an input file is not readable. In either case Zip exits
  858. with an OPEN error and no archive is created.
  859. This option is useful when a known list of files is to be zipped so any
  860. missing or unreadable files should result in an error. It may be less
  861. useful when used with wildcards, but Zip will still exit with an error
  862. if any input pattern doesn't match at least one file or if any
  863. matched files are unreadable. If you want to create the archive anyway
  864. and only need to know if files were skipped, then don't use /MUST_MATCH
  865. and just check the exit status. Also, a log file (see /LOG_FILE) could
  866. be useful.
  867. <QUALIFIER>
  868. /PATTERN_CASE
  869. /PATTERN_CASE={BLIND|SENSITIVE}
  870. <LITERAL>
  871. | BLIND Use case-blind pattern matching for archive entry names.
  872. | SENSITIVE Use case-sensitive pattern matching for archive entry
  873. | names. (Default.)
  874. <LARETIL>
  875. By default, on VMS, archive name pattern matching (/COPY_ENTRIES,
  876. /DELETE, /EXCLUDE, /INCLUDE, and /RECURSE=FILENAMES) is case sensitive,
  877. even when the file system is not case sensitive (or even case
  878. preserving). This allows accurate matching of mixed-case names in an
  879. archive which may have been created on a system with a case sensitive
  880. file system, but it can involve extra effort on VMS, where it may be
  881. necessary to use unnatural case names (or the same names in multiple
  882. cases, like "*.obj *.OBJ") for this kind of pattern matching to give the
  883. desired behavior. If completely case-blind pattern matching behavior is
  884. desired, specify the /PATTERN_CASE=BLIND option.
  885. <QUALIFIER>
  886. /PKZIP
  887. /PKZIP
  888. /NOPKZIP (default)
  889. Create PKZIP-compatible archive entries. File names and paths are
  890. adjusted to conform to MSDOS character-set and length
  891. limitations, to store only the MSDOS file attributes (just the
  892. owner:write attribute from VMS), and to mark the entry as made under
  893. MSDOS (even though it wasn't).
  894. <QUALIFIER>
  895. /PRESERVE_CASE
  896. /NOPRESERVE_CASE
  897. /PRESERVE_CASE[=(keyword[, ...])]
  898. Directs Zip to preserve the case of, or convert to lower-case, file names
  899. in the archive. Optional keywords are:
  900. <LITERAL>
  901. | NOODS2 Down-case ODS2 file names (default).
  902. | NOODS5 Down-case ODS5 file names.
  903. | ODS2 Preserve case of ODS2 file names.
  904. | ODS5 Preserve case of ODS5 file names (default).
  905. <LARETIL>
  906. By default, file names from an ODS2 file system are converted to lower
  907. case for storage in an archive, while the case of file names from an
  908. ODS5 file system is preserved.
  909. /NOPRESERVE_CASE is equivalent to /PRESERVE_CASE = (NOODS2, NOODS5),
  910. which causes all file names to be converted to lower-case. This is
  911. equivalent to the behavior of Zip before version 3.0.
  912. /PRESERVE_CASE is equivalent to /PRESERVE_CASE = (ODS2, ODS5), which
  913. preserves the case of all file names.
  914. <QUALIFIER>
  915. /QUIET
  916. /QUIET
  917. Quiet mode. Eliminates informational messages and comment prompts.
  918. This mode may be useful in command procedures, or if the Zip operation
  919. is being performed as a background task ("$ spawn/nowait zip /quiet foo
  920. *.c").
  921. <QUALIFIER>
  922. /RECURSE
  923. /RECURSE[=KEYWORD]
  924. /NORECURSE (default)
  925. Directs Zip to recurse into subdirectories.
  926. The optional keywords recognized are:
  927. <LITERAL>
  928. | PATH take patterns as full path specifiers (-r) (default)
  929. | FILENAMES start from current dir;
  930. | only use filename part of file patterns (-R)
  931. <LARETIL>
  932. The optional FILENAMES keyword modifies the recursion algorithm to be
  933. (almost) compatible to PKZIP's behaviour on subdirectory recursion.
  934. On VMS, directory recursion can also be requested by using the
  935. directory depth wildcard ("[...]") in an input file specification.
  936. <QUALIFIER>
  937. /SHOW
  938. /SHOW=(KEYWORD[,KEYWORD[...]])
  939. Controls various diagnostic messages.
  940. The keywords recognized are:
  941. <LITERAL>
  942. | COMMAND Show command line arguments as processed (only, then exit).
  943. | DEBUG Show Debug information.
  944. | FILES Show files to process (only, then exit).
  945. | OPTIONS Show all available command-line options on this system.
  946. <LARETIL>
  947. <QUALIFIER>
  948. /SINCE
  949. /SINCE=VMS_date_time
  950. Restricts the files by date-time when adding, updating, or freshening an
  951. archive. Only files with modification date-times at or later than the
  952. specified date-time are accepted.
  953. See also /BEFORE.
  954. <QUALIFIER>
  955. /SPLIT
  956. /SPLIT = (SIZE=size [, PAUSE [, BELL]] [, VERBOSE])
  957. Enables split archives, specifies the size of the splits, and controls
  958. other related behavior.
  959. SIZE=size specifies the split size. The size is given as a number
  960. followed optionally by a multiplier suffix of k (KB), m (MB, the default
  961. if no suffix is specified), g (GB), or t (TB). (All are powers of 1024,
  962. not 1000). 64K is the minimum split size. For example, the following
  963. command could be used to create a split archive called "foo" from the
  964. contents of the "bar" directory with splits of 670MB, which might be
  965. useful for burning on CDs:
  966. <LITERAL>
  967. | zip /split = size = 670m foo [.bar...]*.*
  968. <LARETIL>
  969. Using /SPLIT without PAUSE as above creates all the splits in the
  970. directory
  971. specified by "foo", in this case the current default directory. This
  972. split mode updates the splits as the archive is being created, requiring
  973. all splits to remain writable, but creates split archives that are
  974. readable by any UnZip that supports split archives. See PAUSE below for
  975. enabling split pause mode which allows splits to be written directly to
  976. removable media.
  977. PAUSE causes Zip to pause between splits to allow
  978. changing removable media, for example. PAUSE uses stream mode to
  979. write splits so unzips that can't read stream mode entries may not
  980. be able to read some entries in the archive. Unless standard encryption
  981. was used, copy mode using /COPY_ENTRIES can convert stream mode entries
  982. to normal entries.
  983. BELL ring the terminal bell when Zip pauses for the next split
  984. destination.
  985. VERBOSE enables verbose splitting and display details of how the
  986. splitting is being done.
  987. Though Zip does not update split archives, Zip provides the option
  988. /OUTPUT to allow split archives to be updated and saved in a new
  989. archive. For example:
  990. <LITERAL>
  991. | zip inarchive.zip foo.c bar.c /output = outarchive.zip
  992. <LARETIL>
  993. reads archive inarchive.zip, even if split, adds the files foo.c and
  994. bar.c, and writes the resulting archive to outarchive.zip. If
  995. inarchive.zip is split, then outarchive.zip defaults to the same split
  996. size. Be aware that outarchive.zip and any split files that are created
  997. with it are always overwritten without warning. This may be changed in
  998. the future.
  999. <QUALIFIER>
  1000. /STORE_TYPES
  1001. /STORE_TYPES=(.ext1,.ext2,... )
  1002. Normally, a file which is already compressed will not be compressed much
  1003. further (if at all) by Zip, and trying to do it can waste considerable
  1004. CPU time. Zip can suppress compression on files with particular types,
  1005. specified with /STORE_TYPES. The default list of types where
  1006. compression is suppressed is /STORE_TYPES=(.Z, .zip, .zoo, .arc, .lzh,
  1007. .arj), and the comparison is case-insensitive.
  1008. /LEVEL=9 will override /STORE_TYPES, causing compression to be attempted
  1009. for all files.
  1010. <QUALIFIER>
  1011. /SYMLINKS
  1012. /SYMLINKS
  1013. Store symbolic links as such in the Zip archive, instead of compressing
  1014. and storing the file referred to by the link. A symbolic link normally
  1015. requires less storage than the actual file, both in the archive, and on
  1016. the destination file system.
  1017. On VMS, symbolic links are supported on ODS5 disks where the C RTL
  1018. supports symbolic links. Full support for symbolic links seems to
  1019. require VMS V8.3, but a Zip program supporting symbolic links may be
  1020. built on VMS V7.3-2.
  1021. <QUALIFIER>
  1022. /TEMP_PATH
  1023. /TEMP_PATH=temp_dir
  1024. When creating a new archive or normally when changing an existing
  1025. archive, Zip will write a temporary file in the archive destination
  1026. directory ("ZIxxxxxxxx", where "xxxxxxxx" is the hexadecimal process ID)
  1027. with the new contents. Then, if and when the Zip job has completed with
  1028. no errors, it will rename the temporary file to the specified archive
  1029. name (replacing the old archive, if any).
  1030. /TEMP_PATH=temp_dir specifies an alternate device:[directory],
  1031. "temp_dir", for the temporary file, but specifying a different device
  1032. will force Zip to copy the temporary file to its final destination
  1033. instead of simply renaming it, and that copying will take more time than
  1034. renaming, especially for a large archive. For example:
  1035. <LITERAL>
  1036. | zip /temp_path = disk$scratch:[tmp] stuff *
  1037. <LARETIL>
  1038. will cause Zip to put its temporary files in the directory
  1039. "disk$scratch:[tmp]", copying the temporary file back to the current
  1040. directory as stuff.zip when it's complete.
  1041. <QUALIFIER>
  1042. /TEST
  1043. /TEST[=UNZIP=unzip_cmd]
  1044. Test the integrity of a Zip archive (the new one, if /OUTPUT is
  1045. specified). If the check fails, the old archive is unchanged and
  1046. (with the /MOVE option) no input files are removed.
  1047. Implementation
  1048. "zip /TEST" actually runs an "unzip -t" command to do the testing, so
  1049. UnZip must be installed properly for this to work.
  1050. With UNZIP=unzip_cmd, Zip uses the UnZip command specified by
  1051. "unzip_cmd" (normally a DCL symbol), instead of the default command,
  1052. "unzip -t". This can be useful if multiple versions of UnZip are
  1053. installed on a system, and the default DCL symbol "UNZIP" would run the
  1054. wrong one (or the logical name DCL$PATH would lead to the wrong one).
  1055. In "unzip_cmd", the string "{}" is replaced by the name of the
  1056. (temporary) archive to be tested, otherwise the name of the archive is
  1057. appended to the end of the command. The exit status is checked for
  1058. success severity.
  1059. <QUALIFIER>
  1060. /TRANSLATE_EOL
  1061. /TRANSLATE_EOL[=KEYWORD]
  1062. Selects conversion of the end-of-line markers in text files. This
  1063. option should be used on text files only. The optional keywords
  1064. recognized are:
  1065. <LITERAL>
  1066. | LF convert LF -> CRLF (UNIX to DOS) (default)
  1067. | CRLF convert CRLF -> LF, strip trailing CTRL-Z's (DOS to UNIX)
  1068. <LARETIL>
  1069. The CRLF option may be useful when a DOS text file has been transfered
  1070. to a VMS disk in stream (or stream_lf) format.
  1071. <QUALIFIER>
  1072. /UNSFX
  1073. /UNSFX
  1074. Strip any prepended data from the Zip archive. ZIP /UNSFX is normally
  1075. used to convert a self-extracting archive to a normal archive by
  1076. removing the UnZip SFX executable from the beginning of the SFX archive.
  1077. Note that a self-extracting archive contains a normal Zip archive, and a
  1078. normal UnZip program can be used to expand it in the normal way. You
  1079. may get a warning about extra bytes at the beginning of the archive (the
  1080. UnZip SFX program), but UnZip should work properly after that. This
  1081. allows data in a self-extracting archive to be accessed on any system,
  1082. not just the target system where its embedded UnZip SFX program runs.
  1083. <QUALIFIER>
  1084. /UPDATE
  1085. /UPDATE
  1086. Update existing archive entries and add new files. If the archive does
  1087. not exist, create it. This is the default mode, so /UPDATE is optional.
  1088. See also /DELETE /DIFFERENCE, /GROW, /FRESHEN.
  1089. <QUALIFIER>
  1090. /VERBOSE
  1091. /VERBOSE[=NORMAL|MORE|DEBUG] [, COMMAND]]
  1092. Verbose mode or print diagnostic version info.
  1093. Normally, when applied to real operations, this option enables the
  1094. display of a progress indicator during compression (see /DISPLAY=DOTS
  1095. for more on dots) and requests verbose diagnostic info about archive
  1096. structure oddities.
  1097. /VERBOSE with no value is equivalent to /VERBOSE=NORMAL. MORE adds more
  1098. messages, and DEBUG adds still more messages.
  1099. When /VERBOSE is the only command line argument, a diagnostic report is
  1100. displayed, showing:
  1101. <LITERAL>
  1102. | o Copyright and other legal notices
  1103. | o Program name, version, and release date
  1104. | o Pointers to Info-ZIP FTP and Web sites
  1105. | o Program build information (compiler type and version, OS version,
  1106. | and the compilation date
  1107. | o Optional features enabled at compile-time
  1108. | o Environment variable definitions (ZIP_OPTS, ZIPOPT)
  1109. <LARETIL>
  1110. This information should be included in bug reports.
  1111. /VERBOSE=COMMAND causes Zip to display the UNIX-style command-line
  1112. argument vector which is generated from the VMS-style CLI command line
  1113. before executing the command. This is of primary interest to program
  1114. developers debugging the CLI.
  1115. <QUALIFIER>
  1116. /VMS
  1117. /VMS[=ALL]
  1118. The /VMS and /VMS=ALL options cause Zip to store VMS file atributes
  1119. (such as file organization, record format, carriage control, and so on)
  1120. in VMS-specific "extra fields" in an archive along with the usual data.
  1121. These extra fields are ignored on non-VMS systems, but on a VMS system,
  1122. they allow UnZip to restore the files with their VMS attributes intact.
  1123. With /VMS, Zip ignores any data in the file after the end-of-file (EOF)
  1124. point (defined by FAT$L_EFBLK and FAT$W_FFBYTE), which works well for
  1125. well-formed files (that is, those with no valid data beyond EOF).
  1126. Portable-format files (Stream_LF, fixed-512) archived with /VMS should
  1127. be extracted properly on a non-VMS system. Files with more complex
  1128. structures, such as indexed files and files with embedded byte counts or
  1129. other such data may be of limited use on other systems. (UnZip on
  1130. non-VMS systems may be able to extract various VMS-format text files,
  1131. however.)
  1132. With /VMS=ALL, Zip processes all allocated blocks for the file
  1133. (including those beyond EOF). When extracted on a VMS system, the
  1134. original file should be reproduced with as much fidelity as possible,
  1135. but on a non-VMS system, most files will be seen as corrupt because of
  1136. the data from beyond EOF.
  1137. <QUALIFIER>
  1138. /WILDCARD
  1139. <LITERAL>
  1140. /NOWILDCARD
  1141. /WILDCARD=NOSPAN
  1142. <LARETIL>
  1143. Controls wildcard processing.
  1144. /NOWILDCARD Wildcard processing is disabled.
  1145. /WILDCARD=NOSPAN Wildcards don't span directory boundaries in paths.
  1146. <QUALIFIER>
  1147. /ZIP64
  1148. /ZIP64
  1149. Forces use of Zip64 archive format, even for small files. This is
  1150. mainly for testing and should never be used. Zip will automatically
  1151. use Zip64 as needed without this option.
  1152. <TOPIC>
  1153. UNIX_Options
  1154. "zip -h" provides a concise list of common command-line options. "zip
  1155. -h2" provides more details. "zip -so" provides a list of all available
  1156. options. "zip -v" shows the program version and available features.
  1157. (The list below was derived from a "zip -so" listing.)
  1158. Short-form options begin with a single hyphen ("-"). Long-form option
  1159. begin with a double hyphen ("--"), and may be abbreviated to any
  1160. unambiguous shorter string. For example:
  1161. <LITERAL>
  1162. | -v
  1163. | --verbose
  1164. | --verb
  1165. <LARETIL>
  1166. To avoid confusion, if a negatable option contains an embedded hyphen
  1167. ("-"), then avoid abbreviating it at the hyphen if you plan to negate
  1168. it. For example, if an option like --some-option were abbreviated to
  1169. --some-, the parser would consider that trailing hyphen to be part of
  1170. the option name, rather than as a negating trailing hyphen. This
  1171. behavior may change in the future, to interpret the trailing hyphen in
  1172. --some- to be negating. (So don't do it.)
  1173. Some options may be negated (or modified) by appending a "-":
  1174. <LITERAL>
  1175. | -la-
  1176. | --show-files-
  1177. <LARETIL>
  1178. Some options take a value, which may immediately follow the option, or
  1179. be separated by a space or "=". For example:
  1180. <LITERAL>
  1181. | -ttmmddyyyy
  1182. | -tt mmddyyyy
  1183. | -tt=mmddyyyy
  1184. <LARETIL>
  1185. <LITERAL0>
  1186. | Sh Long Description
  1187. |----+-------------------+------------------------------------------------
  1188. | 0 store store (instead of compress)
  1189. | 1 compress-1 compress faster (-2, -3, -4, ...)
  1190. | 9 compress-9 compress better
  1191. | ? show the Zip help screen
  1192. | @ names-stdin read input file patterns from SYS$INPUT (1/line)
  1193. | A adjust-sfx adjust self-extracting executable
  1194. | b temp-path path use "path" directory for temporary files
  1195. | C preserve-case preserve case of all file names added to archive
  1196. | C- preserve-case- down-case all file names added to archive
  1197. | C2 preserve-case-2 preserve case of ODS2 names added to archive
  1198. | C2- preserve-case-2- down-case ODS2 file added to archive (default)
  1199. | C5 preserve-case-5 preserve case of ODS5 names added to arcv (dflt)
  1200. | C5- preserve-case-5- down-case ODS5 names added to archive
  1201. | c entry-comments add a comment for each entry added to archive
  1202. | D no-dir-entries do not add archive entries for directories
  1203. | DF difference-archive difference archive: add only changed/new files
  1204. | d delete delete entries in archive
  1205. | db display-bytes display running byte counts
  1206. | dc display-counts display running file counts
  1207. | dd display-dots display progress dots for files (dflt sz = 10MB)
  1208. | dg display-globaldots display progress dots for archive, not each file
  1209. | ds dot-size size set progress dot interval to "size" (MB)
  1210. | du display-usize display original uncompressed size for entries
  1211. | dv display-volume display volume (disk) number as in_disk>out_disk
  1212. | e encrypt encrypt entries, ask for password
  1213. | F fix fix mostly intact archive (try F before FF)
  1214. | FF fixfix salvage what can be salvaged (not as reliable)
  1215. | FS filesync remove archive entries unmatched in file system
  1216. | f freshen update existing entries (only changed files)
  1217. | fd force-descriptors force data descriptors as if streaming
  1218. | fz force-zip64 force use of Zip64 format
  1219. | g grow grow existing archive (unless update or delete)
  1220. | H show the Zip help screen
  1221. | h help show the Zip help screen
  1222. | h2 more-help show extended Zip help
  1223. | i include pat1 [pat2 [...]] include only names matching the patterns
  1224. | J junk-sfx junk (remove) archive preamble (unzipsfx)
  1225. | j junk-paths junk (don't store) dir names, only file names
  1226. | k DOS-names simulate PKZIP-made archive (DOS 8.3 names)
  1227. | L license show software license
  1228. | l to-crlf translate end-of-lines (LF -> CRLF)
  1229. | la log-append append to existing log file
  1230. | lf logfile-path lfile log to log file at lfile (default: new version)
  1231. | li log-info include informational messages in log
  1232. | ll from-crlf translate end-of-lines (CRLF -> LF)
  1233. | MM must-match input file spec must exist (wildcrds must match)
  1234. | m move delete files added to archive
  1235. | n suffixes sfx1[:sfx2[...]] don't compress files with these suffixes
  1236. | nw no-wild no wildcards during add or update
  1237. | O output-file ozf use "ozf" as the output archive (dflt = inp archv)
  1238. | o latest-time set archive date-time to match oldest entry
  1239. | P password password encrypt with supplied "password" string
  1240. | q quiet quiet operation (no info messages)
  1241. | R recurse-patterns recurse subdirs from cur dir, match names only
  1242. | r recurse-paths recurse directories from specified path pats
  1243. | s split-size size split archive at "size" (K/MB) (0: don't split)
  1244. | sb split-bell ring termnl bell at pause for split medium chng
  1245. | sc show-command show command line
  1246. | sd show-debug show debug messages
  1247. | sf show-files show files to process (only)
  1248. | so show-options show list of all command-line options
  1249. | sp split-pause pause to select split destination(s)
  1250. | sv split-verbose be verbose about creating splits
  1251. | T test test archive integrity (runs UnZip -T)
  1252. | t from-date mmddyyyy only do files since (at or after) "mmddyyyy"
  1253. | tt before-date mmddyyyy only do files before "mmddyyyy"
  1254. | u update update changed files, add new files (default)
  1255. | V VMS-portable save VMS file attributes
  1256. | VV VMS-specific save VMS file attributes and all allocated blks
  1257. | v verbose verbose messages (version info if only arg)
  1258. | w VMS-versions save VMS version numbers in archive
  1259. | ww VMS-dot-versions save VMS version numbers as ".nnn", not ";nnn"
  1260. | X strip-extra strip all but critical extra fields
  1261. | X- strip-extra- keep all extra fields
  1262. | x exclude pat1 [pat2 [...]] exclude all names matching the patterns
  1263. | Z compression-method mthd use cmprs method "mthd" (bzip2 or deflate)
  1264. | z archive-comment ask for archive comment
  1265. <0LARETIL>
  1266. With SET PROCESS /PARSE_STYLE = EXTENDED (available on recent non-VAX
  1267. systems), Zip preserves the case of the command line. Otherwise, mixed-
  1268. or upper-case options and arguments must be quoted. For example,
  1269. "-V". Examples in this document generally do not show this quotation.
  1270. <TOPIC>
  1271. Copyright_and_License
  1272. Zip has an option to display its copyright and license.
  1273. <LITERAL>
  1274. | /LICENSE
  1275. <LARETIL>
  1276. The license is reproduced below.
  1277. This is version 2007-Mar-4 of the Info-ZIP license. The definitive
  1278. version of this document should be available at
  1279. ftp://ftp.info-zip.org/pub/infozip/license.html indefinitely and a copy
  1280. at http://www.info-zip.org/pub/infozip/license.html.
  1281. --------------------------------------------------------
  1282. <LITERAL0>
  1283. |Copyright (c) 1990-2007 Info-ZIP. All rights reserved.
  1284. |
  1285. |For the purposes of this copyright and license, "Info-ZIP" is defined as
  1286. |the following set of individuals:
  1287. |
  1288. |Mark Adler, John Bush, Karl Davis, Harald Denker, Jean-Michel Dubois,
  1289. |Jean-loup Gailly, Hunter Goatley, Ed Gordon, Ian Gorman, Chris Herborth,
  1290. |Dirk Haase, Greg Hartwig, Robert Heath, Jonathan Hudson, Paul Kienitz,
  1291. |David Kirschbaum, Johnny Lee, Onno van der Linden, Igor Mandrichenko,
  1292. |Steve P. Miller, Sergio Monesi, Keith Owens, George Petrov, Greg Roelofs,
  1293. |Kai Uwe Rommel, Steve Salisbury, Dave Smith, Steven M. Schweda,
  1294. |Christian Spieler, Cosmin Truta, Antoine Verheijen, Paul von Behren,
  1295. |Rich Wales, Mike White.
  1296. |
  1297. |This software is provided "as is," without warranty of any kind, express
  1298. |or implied. In no event shall Info-ZIP or its contributors be held
  1299. |liable for any direct, indirect, incidental, special or consequential
  1300. |damages arising out of the use of or inability to use this software.
  1301. |
  1302. |Permission is granted to anyone to use this software for any purpose,
  1303. |including commercial applications, and to alter it and redistribute it
  1304. |freely, subject to the above disclaimer and the following restrictions:
  1305. |
  1306. |1. Redistributions of source code (in whole or in part) must retain
  1307. | the above copyright notice, definition, disclaimer, and this list
  1308. | of conditions.
  1309. |
  1310. |2. Redistributions in binary form (compiled executables and libraries)
  1311. | must reproduce the above copyright notice, definition, disclaimer,
  1312. | and this list of conditions in documentation and/or other materials
  1313. | provided with the distribution. The sole exception to this condition
  1314. | is redistribution of a standard UnZipSFX binary (including SFXWiz) as
  1315. | part of a self-extracting archive; that is permitted without inclusion
  1316. | of this license, as long as the normal SFX banner has not been removed
  1317. | from the binary or disabled.
  1318. |
  1319. |3. Altered versions -- including, but not limited to, ports to new
  1320. | operating systems, existing ports with new graphical interfaces,
  1321. | versions with modified or added functionality, and dynamic, shared,
  1322. | or static library versions not from Info-ZIP -- must be plainly marked
  1323. | as such and must not be misrepresented as being the original source
  1324. | or, if binaries, compiled from the original source. Such altered
  1325. | versions also must not be misrepresented as being Info-ZIP releases --
  1326. | including, but not limited to, labeling of the altered versions with
  1327. | the names "Info-ZIP" (or any variation thereof, including, but not
  1328. | limited to, different capitalizations), "Pocket UnZip," "WiZ" or
  1329. | "MacZip" without the explicit permission of Info-ZIP. Such altered
  1330. | versions are further prohibited from misrepresentative use of the
  1331. | Zip-Bugs or Info-ZIP e-mail addresses or the Info-ZIP URL(s), such as
  1332. | to imply Info-ZIP will provide support for the altered versions.
  1333. |
  1334. |4. Info-ZIP retains the right to use the names "Info-ZIP", "Zip",
  1335. | "UnZip", "UnZipSFX", "WiZ", "Pocket UnZip", "Pocket Zip", and
  1336. | "MacZip" for its own source and binary releases.
  1337. <0LARETIL>
  1338. ===