funzip.1
资源名称:unzip540.zip [点击查看]
上传用户:andy_li
上传日期:2007-01-06
资源大小:1019k
文件大小:5k
源码类别:
压缩解压
开发平台:
MultiPlatform
- ." Info-ZIP grants permission to any individual or institution to use, copy,
- ." or redistribute this software, so long as: (1) all of the original files
- ." are included; (2) it is not sold for profit; and (3) this notice is re-
- ." tained. See the UnZip COPYING file for details.
- ."
- ." funzip.1 by Greg Roelofs and others.
- ."
- ." =========================================================================
- ." define .Y macro (for user-command examples; normal Courier font):
- .de Y
- .ft CW
- .in +4n
- .nf
- &\$1
- .ft
- .in
- .fi
- ..
- ." =========================================================================
- .TH FUNZIP 1L "28 November 1998 (v3.93)" "Info-ZIP"
- .SH NAME
- funzip - filter for extracting from a ZIP archive in a pipe
- .PD
- .SH SYNOPSIS
- [.|.|.] | fBfunzipfP [fB-passwordfP] | [.|.|.]
- .PP
- fBfunzipfP [fB-passwordfP] fIinput.zipfP | [.|.|.]
- fBfunzipfP [fB-passwordfP] fIinput.gzfP | [.|.|.]
- ." =========================================================================
- .SH ARGUMENTS
- .IP [fI-passwordfP]
- Optional password to be used if ZIP archive is encrypted. Decryption
- may not be supported at some sites. See DESCRIPTION for more details.
- .PD
- ." =========================================================================
- .SH DESCRIPTION
- .I funzip
- acts as a filter; that is, it assumes that a ZIP archive (or a fIgzipfP'd(1)
- file) is being piped into
- standard input, and it extracts the first member from the archive to stdout.
- If there is an argument, then the input comes from the specified file
- instead of from stdin. A password for encrypted zip files can be specified
- on the command line (preceding the file name, if any) by prefixing the
- password with a dash. Note that this constitutes a security risk on many
- systems; currently running processes are often visible via simple commands
- (e.g., fIpsfP(1) under Unix), and command-line histories can be read.
- If the first entry of the zip file is encrypted and
- no password is specified on the command line, then the user is prompted for
- a password and the password is not echoed on the console.
- .PP
- Given the limitation on single-member extraction, fIfunzipfP is most
- useful in conjunction with a secondary archiver program such as fItarfP(1).
- The following section includes an example illustrating this usage in the
- case of disk backups to tape.
- .PD
- ." =========================================================================
- .SH EXAMPLES
- To use fIfunzipfP to extract the first member file of the archive test.zip
- and to pipe it into fImorefP(1):
- .PP
- .Y "funzip test.zip | more"
- .PP
- To use fIfunzipfP to test the first member file of test.zip (any errors
- will be reported on standard error):
- .PP
- .Y "funzip test.zip > /dev/null"
- .PP
- To use fIzipfP and fIfunzipfP in place of fIcompressfP(1) and
- fIzcatfP(1) (or fIgzipfP(1L) and fIgzcatfP(1L)) for tape backups:
- .PP
- .PD 0
- .Y "tar cf - . | zip -7 | dd of=/dev/nrst0 obs=8k"
- .Y "dd if=/dev/nrst0 ibs=8k | funzip | tar xf -"
- .PD
- .PP
- (where, for example, nrst0 is a SCSI tape drive).
- .PD
- ." =========================================================================
- .SH BUGS
- When piping an encrypted file into fImorefP and allowing fIfunzipfP
- to prompt for password, the terminal may sometimes be reset to a non-echo
- mode. This is apparently due to a race condition between the two programs;
- fIfunzipfP changes the terminal mode to non-echo before fImorefP reads
- its state, and fImorefP then ``restores'' the terminal to this mode before
- exiting. To recover, run fIfunzipfP on the same file but redirect to
- /dev/null rather than piping into more; after prompting again for the
- password, fIfunzipfP will reset the terminal properly.
- .PP
- There is presently no way to extract any member but the first from a ZIP
- archive. This would be useful in the case where a ZIP archive is included
- within another archive. In the case where the first member is a directory,
- fIfunzipfP simply creates the directory and exits.
- .PP
- The functionality of fIfunzipfP should be incorporated into fIunzipfP
- itself (future release).
- .PD
- ." =========================================================================
- .SH "SEE ALSO"
- fIgzipfP(1L), fIunzipfP(1L), fIunzipsfxfP(1L), fIzipfP(1L),
- fIzipcloakfP(1L), fIzipinfofP(1L), fIzipnotefP(1L), fIzipsplitfP(1L)
- .PD
- ." =========================================================================
- .SH URL
- The Info-ZIP home page is currently at fChttp://www.cdrom.com/pub/infozip/fR .
- .PD
- ." =========================================================================
- .SH AUTHOR
- Mark Adler (Info-ZIP)