Go to main content

man pages section 1: User Commands

Exit Print View

Updated: Wednesday, July 27, 2022

streamzip (1)


streamzip - create a zip file from stdin


producer | streamzip [opts] | consumer
producer | streamzip [opts] -zipfile=output.zip


Perl Programmers Reference Guide                                  STREAMZIP(1)

       streamzip - create a zip file from stdin

           producer | streamzip [opts] | consumer
           producer | streamzip [opts] -zipfile=output.zip

       This program will read data from stdin, compress it into a zip
       container and, by default, write a streamed zip file to stdout. No
       temporary files are created.

       The zip container written to stdout is, by necessity, written in
       streaming format.  Most programs that read Zip files can cope with a
       streamed zip file, but if interoperability is important, and your
       workflow allows you to write the zip file directly to disk you can
       create a non-streamed zip file using the "zipfile" option.

            Create a Zip64-compliant zip container.  Use this option if the
            input is greater than 4Gig.

            Default is disabled.

            Write zip container to the filename F.

            Use the "Stream" option to enable the creation of a  streamed zip

            This option is used to name the "file" in the zip container.

            Default is '-'.

            Ignored when writing to stdout.

            If the "zipfile" option is specified, including this option will
            trigger the creation of a streamed zip file.

            Default: Always enabled when writing to stdout, otherwise

            Compress using method "M".

            Valid method names are

                * store    Store without compression
                * deflate  Use Deflate compression [Deflault]
                * bzip2    Use Bzip2 compression
                * lzma     Use LZMA compression

            Note that Lzma compress needs IO::Compress::Lzma to be installed.

            Default is deflate.

            Display version number [$VERSION]

            Display help

   When to use a Streamed Zip File
       A Zip file created with streaming mode enabled allows you to create a
       zip file in situations where you cannot seek backwards/forwards in the

       A good examples is when you are serving dynamic content from a Web
       Server straight into a socket without needing to create a temporary zip
       file in the filesystsm.

       Similarly if your workfow uses a Linux pipelined commands.

       General feedback/questions/bug reports should be sent to
       <https://github.com/pmqs/IO-Compress/issues> (preferred) or

       Paul Marquess pmqs@cpan.org.

       Copyright (c) 2019 Paul Marquess. All rights reserved.

       This program is free software; you can redistribute it and/or modify it
       under the same terms as Perl itself.

       See attributes(7) for descriptions of the following attributes:

       |Availability   | runtime/perl-532      |
       |Stability      | Pass-through volatile |

       Source code for open source software components in Oracle Solaris can
       be found at https://www.oracle.com/downloads/opensource/solaris-source-

       This software was built from source available at
       https://github.com/oracle/solaris-userland.  The original community
       source was downloaded from

       Further information about this software can be found on the open source
       community website at https://www.perl.org/.

perl v5.32.0                      2022-06-28                      STREAMZIP(1)