📄 vms_zip.rnh
字号:
zip file. The same is true of -u, and hence "zip -u foo" and "zip -f foo"both do the same thing..skThis command should be run from the same directory from which the originalzip command was run, since paths stored in zip files are always relative..skAnother restriction that can be used with adding, updating, or fresheningis -t (time), which will not operate on files modified earlier than thespecified date. For example:.sk;.indent 10$ zip -rt 120791 infamy [.FOO]*.*.skwill add all the files in [.FOO] and its subdirectories that were lastmodified on December 7, 1991, or later to the zip file INFAMY.ZIP..skAlso, files can be explicitly excluded using the -x option:.sk;.indent 10$ zip -r foo [.FOO] -x *.obj.skwhich will zip up the contents of [.FOO] into FOO.ZIP but exclude all thefiles that end in ".OBJ"..skThe last operation is -d (delete) which will remove entries from a zipfile. An example might be:.sk;.indent 10$ zip -d foo foo/harry/*.* *.obj.skwhich will remove all of the files that start with "foo/harry/" and all ofthe files that end with ".OBJ" (in any path)..skUnder MSDOS, -d is case sensitive when it matches names in the zip file.This allows deleting names that were zipped on other systems, but requiresthat the names be entered in upper case if they were zipped on an MSDOSsystem, so that the names can be found in the zip file and deleted..!------------------------------------------------------------------------------.indent -42 More_Options.brAs mentioned before, Zip will use the best of two methods: deflate or store.The option -0 will force Zip to use store on all files. For example:.sk;.indent 10zip -r0 foo foo.skwill zip up the directory foo into foo.zip using only store..skThe speed of deflation can also be controlled with options -1 (fastestmethod but less compression) to -9 (best compression but slower). Thedefault value is -5. For example:.sk;.indent 10zip -r8 foo foo.skIn nearly all cases, a file that is already compressed cannot be compressedfurther by Zip, or if it can, the effect is minimal. The -n optionprevents Zip from trying to compress files that have thegiven suffixes. Such files are simply stored (0%compression) in theoutput zip file, so that Zip doesn't waste its time trying to compressthem. The suffixes are separated byeither colons or semicolons. For example, in DCL:.sk.indent 10;$ zip -rn ".Z:.zip:.tiff:.gif:.snd" foo [.FOO]*.*.skwill put everything in [.FOO] into FOO.ZIP, but will store any files that endin .Z, .ZIP, .TIFF, .GIF, or .SND without trying to compress them. (Image andsound files often have their own specialized compression methods.)The default suffix list is ".Z:.zip;.zoo:.arc:.lzh:.arj".The environment variable ZIPOPT can be used to change this default. Forexample:.sk.indent 10;$ ZIPOPT == "-n .Z:.zip:.tiff:.gif:.snd".skThe variable ZIPOPT can be used for any option and can include severaloptions..skUnder Unix and under OS/2 (if files from a HPFS are stored), Zip will storethe full path (relative to the current path) and name of the file (or justthe name if -j is specified) in the zip file along with the Unixattributes, and it will mark the entry as made under Unix. If the zip fileis intended for PKUNZIP under MSDOS, then the -k (Katz) option should beused to attempt to convert the names and paths to conform to MSDOS, storeonly the MSDOS attribute (just the user write attribute from Unix), andmark the entry as made under MSDOS (even though it wasn't)..skThe -o (older) option will set the "last modified" time of the zip file tothe latest "last modified" time of the entries in the zip file. This canbe used without any other operations, if desired. For example:.sk;.indent 10$ zip -o foo.skwill change the last modified time of FOO.ZIP to the latest time of theentries in FOO.ZIP..skThe -e and -c options operate on all files updated or added to the zipfile. Encryption (-e) will prompt for a password on the terminal and willnot echo the password as it is typed (if stderr is not a TTY, Zip will exitwith an error). New zip entries will be encrypted using that password. Foradded peace of mind, you can use -ee, which will prompt for the passwordtwice, checking that the two are the same before using it..skOne-line comments can be added for each file with the -c option. The zipfile operations (adding or updating) will be done first, and you will thenbe prompted for a one-line comment for each file. You can then enter thecomment followed by return, or just return for no comment..skThe -z option will prompt you for a multi-line comment for the entire zipfile. This option can be used by itself, or in combination with otheroptions. The comment is ended by a line containing just a period, or anend of file condition (^D on Unix, ^Z on MSDOS, OS/2, and VAX/VMS)..skThe -q (quiet) option eliminates the informational messages and commentprompts while Zip is operating. This might be used in shell scripts, forexample, or if the zip operation is being performed as a background task("$ spawn/nowait zip -q foo *.c")..skZip can take a list of file names to operate on from SYS$INPUT using the"-@"option..! In Unix, this option can be used with the find command to extend.!greatly the functionality of Zip. For example, to zip up all the C source.!files in the current directory and its subdirectories, you can:.!.sk.!find . -type f -name "*.[ch]" -print | zip source -@.!.sk.!Note that the pattern must be quoted to keep the shell from expanding it..skUnder VMS only, the -w option will append the version number of the filesto the name and zip up multiple versions of files. Without -w, Zip willonly use the most recent version of the specified file(s)..skOne more option that valid only under VMS is -V option. This option savesall (hopefully) file attributes needed to make EXACT copy of thefile after extraction from archive. To extract a file with saved attributesuse UnZip version 4.2 or later. Note that to specify this option you shouldquote it ("-V"). Be carefull: it's rather hard (if possible at all) to extracta file archived on VMS with this option specified on other systems. See documentation on UnZip for further information..skThe -l option translates the Unix end-of-line character LF into theMSDOS convention CR LF. This option should not be used on binary files.This option can be used on Unix if the zip file is intended for PKUNZIPunder MSDOS..skIf Zip is run with the -h option, or with no arguments and standard output isa terminal, the license and the command-argument and option help is shown.The -L option just shows the license..!------------------------------------------------------------------------------.indent -42 Copyright.br Copyright (C) 1990,1991 Mark Adler, Richard B. Wales, Jean-loup Gailly, Igor Mandrichenko and Kai Uwe Rommel. Permission is granted to any individual or institution to use, copy, or redistribute this software so long as all of the original files are included, that it is not sold for profit, and that this copyright notice is retained..!------------------------------------------------------------------------------.indent -42 Acknowledgements.br Thanks to R. P. Byrne for his Shrink.Pas program, which inspired this project, and from which the shrink algorithm was stolen; to Phil Katz for placing in the public domain the zip file format, compression format, and .ZIP filename extension, and for accepting minor changes to the file for- mat; to Steve Burg for clarifications on the deflate format; to Keith Petersen, Rich Wales, Hunter Goatley and Mark Adler for providing a mailing list and ftp site for the INFO-ZIP group to use; and most importantly, to the INFO-ZIP group itself (listed in the file infozip.who) without whose tire- less testing and bug-fixing efforts a portable zip would not have been possible. Finally we should thank (blame) the first INFO-ZIP moderator, David Kirschbaum, for getting us into this mess in the first place..!------------------------------------------------------------------------------.indent -42 Bugs.sk WARNING: zip files produced by this version of zip must not be *updated* by zip 1.0 or pkzip 1.10 or pkzip 1.93a, if they contain encrypted members, or if they have been produced in a pipe or on a non seekable device. The old versions of zip or pkzip would destroy the zip structure. The old versions can list the contents of the zip file but cannot extract it anyway (because of the new compression algorithm). If you do not use encryption and use regular disk files, you do not have to care about this problem..sk Under VMS, not all of the odd file formats are treated properly. Only zip files of format stream-LF and fixed length 512 are expected to work with Zip. Others can be converted using Rahul Dhesi's BILF program. This version of Zip does handle some of the conversion internally. When using Kermit to transfer zip files from Vax to MSDOS, type "set file type block" on the Vax. When transfering from MSDOS to Vax, type "set file type fixed" on the Vax. In both cases, type "set file type binary" on MSDOS..sk Under VMS, zip hangs for file specification that uses DECnet syntax (foo::*.*)..sk LIKE ANYTHING ELSE THAT'S FREE, ZIP AND ITS ASSOCIATED UTILITIES ARE PROVIDED AS IS AND COME WITH NO WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED. IN NO EVENT WILL THE COPYRIGHT HOLDERS BE LIABLE FOR ANY DAMAGES RESULTING FROM THE USE OF THIS SOFTWARE..sk That having been said, please send any problems or comments via email to the Internet address zip-bugs@wkuvx1.bitnet. For bug reports, please include the version of Zip, the make options you used to compile it, the machine and operating system you are using, and as much additional information as possible. Thank you for your support..!------------------------------------------------------------------------------
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -